Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要使用 JUnit 3,我知道在 JUnit 4 中有一个方法可以从 Java 中的普通方法启动 JUnit 测试(结果 r = org.junit.runner.JUnitCore.runClasses(MyTestClass.class) )。但是我怎样才能在 JUnit 3 中做到这一点并获得结果呢?
编辑:我现在这样做:TestRunner.run(MyTestClass.class); 但后来我没有得到任何结果..
我认为这应该可行:http: //pub.admc.com/howtos/junit3x/junit3x.html#using_runners-chapt