org.testng.TestNGException

The test(s) <[]> cannot be found.


Solutions on the web141

Solution icon of web
via co.in by Unknown author, 1 year ago
Test element must define the name attribute

Solution icon of github
via GitHub by tyrel
, 1 year ago
> Cannot find class in classpath: <redacted test class name>

Solution icon of stackoverflow
Cannot instantiate class Test at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:38)

Solution icon of stackoverflow
Method testFireFox requires 2 parameters but 0 were supplied in the @Test annotation.

Solution icon of stackoverflow
Method PopulateBorrower requires 2 parameters but 0 were supplied in the @Test annotation.

Solution icon of stackoverflow
Method main requires 1 parameters but 0 were supplied in the @Test annotation.

Solution icon of web
via codegur.com by Unknown author, 1 year ago
Method testFireFox requires 2 parameters but 0 were supplied in the @Test annotation.

Solution icon of web
Method helperMethod requires 2 parameters but 0 were supplied in the @Test annotation.

Solution icon of stackoverflow
Method helperMethod requires 2 parameters but 0 were supplied in the @Test annotation.

Stack trace

  • org.testng.TestNGException: The test(s) <[]> cannot be found. at org.testng.TestNG.extractTestNames(TestNG.java:436) at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:310) at org.testng.TestNG.run(TestNG.java:1088) at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:281) at org.apache.maven.surefire.testng.TestNGXmlTestSuite.execute(TestNGXmlTestSuite.java:75) at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:121) at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:290) at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:242) at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:121)

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

Samebug visitor profile picture
Unknown user
2 times, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago