0

I have two files: thing.java and thingTester.java, the latter is using the methods defined in the "thing" class so I can test those methods.

In addition to those two files, I have junit-4.12.jar in the same directory, so I have only those 3 files in my working directory.

Compiled using this (on Unix):

javac -cp .:junit-4.12.jar thingTester.java thing.java 

Trying to run using the line below, but I get "java.lang.NoClassDefFoundError":

java -cp .:junit-4.12.jar junit.textui.TestRunner thingTester thing

What am I doing wrong? I can't really find any clear documentation or general examples.

rawa
  • 315
  • 3
  • 8
  • 20

0 Answers0