JUnit issues with EAP
I've been getting the following exception occasionally when I try to run JUnit tests using the current EAP build. The project containing the tests contains an older version of junit.jar (v4.1, I believe). The tests run correctly in IDEA 8.1.4. This isn't a new problem with the current EAP build - it happened in the previous version (which was the first EAP build I tried).
Exception in thread "main" java.lang.NoSuchMethodError: org.junit.runner.Description.getAnnotation(Ljava/ang/lass;)Ljava/ang/nnotation/nnotation;
at com.intellij.junit4.JUnit4TestResultsSender.testIgnored(JUnit4TestResultsSender.java:58)
at org.junit.runner.notification.RunNotifier$5.notifyListener(RunNotifier.java:109)
at org.junit.runner.notification.RunNotifier$SafeNotifier.run(RunNotifier.java:37)
at org.junit.runner.notification.RunNotifier.fireTestIgnored(RunNotifier.java:106)
at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:36)
at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:66)
at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at org.junit.runner.JUnitCore.run(JUnitCore.java:130)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:94)
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:165)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:110)
Please sign in to leave a comment.
Hello Dan,
What exactly do you mean by "the current EAP build"? There's no current EAP
build - IntelliJ 9.0 final has been released.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
I saw this problem in build 90.193 and 92.105. I didn't notice that the final version was released this week.
It looks like Intellij 9 needs junit 4.4 or above. Have created http://youtrack.jetbrains.net/issue/IDEA-26786 as a result.