0

Im using Eclipse Juno. I imported a SVN (Subversion) project. I am trying to unit test the java classes on a module. I am using Java Perspective.

build path library has Junit4.

I have this Problems:

  1. When im adding a new JUnit test case, the textbox from "class under test" has an error of "class under test doesnt exist in current project". But I just right clicked the java class I want to be tested and add new JUnit Test Case.So basically the error showing up doesnt make any sense. Because the class under test exist.

  2. Theres no "run as JUnit Test" in the existing Java Test Class imported from SVN. if I right clicked the test class > run as > run config only ***Theres no Junit Test

Eclipse Setup is Default except this settings:

in Window> Preferences > Java> Installed JRE > Jdk 1.7 in Window> Preferences > Maven > Installtion > Maven 3.0.4 (External)

Please Help me, consider me as a newbie in Unit Testing and in SVN Projects. I dont have any idea what to do.

Can anyone teach me how to create a Junit Test Case from a test class of a SVN Project. Can You also Instruct the proper Eclipse Settings. (Files and Instructions)

Thanks in advance.

error image error image 2

4

1 に答える 1

0

JUnit をビルドパスに追加すると、問題の一部または両方が解決されます。最初の問題を再現できませんでしたが、これを Indigo でテストしました。

于 2012-11-16T14:52:08.683 に答える