1

Getting this strange error while I'm pretty sure that the classpath is perfect. The error is not even revealing the class name it can't locate. Any pointers please!

The command I'm running on command prompt under the project directory, is this:

java -classpath randoop-all-3.0.1.jar;web/app/WEB-INF/classes/;C:/jdk-8u74-windows-x64/lib/missioncontrol/plugins/javax.servlet_3.0.0.v201112011016.jar randoop.main.Main gentests --classlist=myclasses.txt --timelimit=60

The error generated is this:

Throwable thrown while handling command: java.lang.Error: No class found for type name ""
java.lang.Error: No class found for type name ""
        at randoop.main.ThrowClassNameError.handle(ThrowClassNameError.java:11)
        at randoop.reflection.OperationModel.addClassTypes(OperationModel.java:293)
        at randoop.reflection.OperationModel.createModel(OperationModel.java:136)
        at randoop.main.GenTests.handle(GenTests.java:194)
        at randoop.main.Main.nonStaticMain(Main.java:61)
        at randoop.main.Main.main(Main.java:27)

Randoop failed.
Last sequence under execution: null
Sau
  • 23
  • 5

1 Answers1

0

The error message says that you have provided an empty string as a class name to Randoop. Your command line supplies class names via the --classname command-line argument. Therefore, my guess is that there is a blank line, or a line containing just spaces, in your myclasses.txt file.

I don't know for certain because your problem report is incomplete. For better help, in the future please provide all the files needed to reproduce the problem, including the myclasses.txt file and the .jar files.

mernst
  • 7,437
  • 30
  • 45