This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Hello, I downloaded JUnit from www.junit.org and want to start it. I added it to the class path:
set CLASSPATH=.;c:\Java\SCP2Certification\junit3\junit.jar Below are the installation steps for installing JUnit: 1. unzip the junit.zip file 2. add junit.jar to the CLASSPATH. For example: set classpath=%classpath%;INSTALL_DIR\junit3\junit.jar 3. test the installation by using either the batch or the graphical TestRunner tool to run the tests that come with this release. All the tests should pass OK. Notice: that the tests are not contained in the junit.jar but in the installation directory directly. Therefore make sure that the installation directory is on the class path for the batch TestRunner type: java junit.textui.TestRunner junit.samples.AllTests for the graphical TestRunner type: java junit.awtui.TestRunner junit.samples.AllTests for the Swing based graphical TestRunner type: java junit.swingui.TestRunner junit.samples.AllTests Important: don't install the junit.jar into the extension directory of your JDK installation. If you do so the test class on the files system will not be found. Junit is installed on path c:\Java\SCP2Certification\junit3.8.1\junit3.8.1\junit.jar and my SDK1.4 is installed on c:\Java\SDK1.4 So junit is not installed as extention of SDK1.4. When I start programm with java junit.textui.TestRunner junit.samples.AllTests I get: java junit.awtui.TestRunner junit.samples.AllTests java.lang.NoClassDefFoundError: junit/awtui/TestRunner Exception in thread "main" mfg Thomas Markl
In your post, your classpath setting doesn't match the location where the JUnit jar file is. c:\Java\SCP2Certification\junit3.8.1\junit3.8.1\junit.jar set CLASSPATH=.;c:\Java\SCP2Certification\junit3\junit.jar