java.lang.NoSuchMethodError when running TestNG test

Answered

I'm using IDEA 2016.1 with jdk1.7.0_40. Bundled TestNG-J plugin v8.0 is on. When I'm trying to run test class I get the following error:

Exception in thread "main" java.lang.NoSuchMethodError: org.testng.IDEARemoteTestNG.configure(Lorg/testng/CommandLineArgs;)V
at org.testng.RemoteTestNGStarter.main(RemoteTestNGStarter.java:120)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:144) 


6 comments

Thanks. Updating TestNG dependency to 6.9.8 helped

0

Exception in thread "main" java.lang.NoSuchMethodError: org.testng.IDEARemoteTestNG.configure(Lorg/testng/CommandLineArgs;)V
    at org.testng.RemoteTestNGStarter.main(RemoteTestNGStarter.java:126)

Above error found when running intellij
Please guide!

0

Not worked!
I have IntelliJ IDEA 2017.1.5
and testNG dependency like below

<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>6.11</version>
<scope>test</scope>
</dependency>
0

Please file a bug at https://youtrack.jetbrains.com/issues/IDEA with a complete sample project to reproduce.

0

Please sign in to leave a comment.