[GRADLE-1860] TestNG 6.3 is not supported Created: 22/Oct/11  Updated: 04/Jan/13  Resolved: 04/Dec/11

Status: Resolved
Project: Gradle
Affects Version/s: 1.0-milestone-4
Fix Version/s: 1.0-milestone-7

Type: Bug
Reporter: Nikolay Rybak Assignee: Peter Niederwieser
Resolution: Fixed Votes: 4


TestNG 6.3 removed support for Javadoc annotations as well as method TestNG.setAnnotations() to set annotations type (see commit), therefore any attempt to run tests with TestNG 6.3 in Gradle fails with

Caused by: java.lang.NoSuchMethodError: org.testng.TestNG.setAnnotations(Ljava/lang/String;)V
        at org.gradle.api.internal.tasks.testing.testng.TestNGTestClassProcessor.stop(TestNGTestClassProcessor.java:71)
        at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:58)
        ... 31 more

Comment by Russel Winder [ 28/Nov/11 ]

Well this sucks. I guess this has to be considered a Gradle bug?

Comment by Russel Winder [ 28/Nov/11 ]

BTW Not just a Windows problem, also a Debian Unstable issue.

Not to mention Gradle 1.0-milestone-6 and indeed HEAD (1.0-milestone-7) as of a few days ago.

Comment by Peter Niederwieser [ 28/Nov/11 ]

It's caused by a breaking API change in TestNG. Maybe the offending method call can just be removed. Pull request appreciated.

Generated at Wed Jun 30 12:06:19 CDT 2021 using Jira 8.4.2#804003-sha1:d21414fc212e3af190e92c2d2ac41299b89402cf.