What CLASSPATH Settings Are Needed to Run JUnit
What CLASSPATH Settings Are Needed to Run JUnit?
✍: FYICenter.com QA Team
It doesn't matter if you run your JUnit tests from a command line, from an IDE, or from "ant", you must define your CLASSPATH settings correctly. Here is what recommended by the JUnit FAQ with some minor changes:
To run your JUnit tests, you'll need the following elemements in your CLASSPATH:
If attempting to run your tests results in a NoClassDefFoundError, then something is missing from your CLASSPATH.
If you are running your JUnit tests from a command line on a Windows system:
set CLASSPATH=c:\A\junit-4.4.jar;c:\B\test_classes; c:\B\target_classes;c:\D\3rd_party.jar
If you are running your JUnit tests from a command line on a Unix (bash) system:
export CLASSPATH=/A/junit-4.4.jar:/B/test_classes: /C/target_classes:/D/3rd_party.jar
2008-01-15, 6202👍, 0💬
What is the purpose of the wait(), notify(), and notifyAll() methods? The wait(),notify(), and notif...
What is the benefit of using an enum rather than a #define constant? The use of an enumeration const...
How Many Types of Tables Supported by Oracle? - Oracle DBA FAQ - Managing Oracle Database Tables Ora...
Can you explain duplex contracts in WCF? In duplex contracts when client initiates an operation the ...
How To Enter Numeric Values as HEX Numbers? - MySQL FAQs - Introduction to SQL Basics If you want to...