尝试在Eclipse中设置新的JUNIT类时出现“未找到类”错误

时间:2017-11-17 14:35:25

标签: eclipse class junit

在为uni项目设置JUNIT类时,我不断收到以下错误(在Eclipse Oxygen中工作):

Class not found UnitTest
java.lang.ClassNotFoundException: UnitTest
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.loadClass(RemoteTestRunner.java:688)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.loadClasses(RemoteTestRunner.java:421)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:444)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)

无法弄清楚最新情况,已经尝试了一些与问题相关的答案,例如清理项目并检查测试是否从我的project / bin文件夹中运行。

0 个答案:

没有答案