[testng]
[testng] [Utils] [ERROR] [Error] org.testng.TestNGException:
[testng] Cannot inject @Test annotated Method [describes] with [class java.lang.String, interface kotlin.jvm.functions.Function1].
[testng] For more information on native dependency injection please refer to http://testng.org/doc/documentation-main.html#native-dependency-injection
[testng] at org.testng.internal.Parameters.checkParameterTypes(Parameters.java:407)
[testng] at org.testng.internal.Parameters.createParametersForMethod(Parameters.java:356)
[testng] at org.testng.internal.Parameters.createParameters(Parameters.java:635)
[testng] at org.testng.internal.Parameters.handleParameters(Parameters.java:769)
[testng] at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:49)
[testng] at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:37)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:923)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
[testng] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[testng] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[testng] at java.lang.Thread.run(Thread.java:748)
[testng]
[testng] [Utils] [ERROR] [Error] org.testng.TestNGException:
[testng] Cannot inject @Test annotated Method [xdescribes] with [class java.lang.String, interface kotlin.jvm.functions.Function1].
[testng] For more information on native dependency injection please refer to http://testng.org/doc/documentation-main.html#native-dependency-injection
[testng] at org.testng.internal.Parameters.checkParameterTypes(Parameters.java:407)
[testng] at org.testng.internal.Parameters.createParametersForMethod(Parameters.java:356)
[testng] at org.testng.internal.Parameters.createParameters(Parameters.java:635)
[testng] at org.testng.internal.Parameters.handleParameters(Parameters.java:769)
[testng] at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:49)
[testng] at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:37)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:923)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
[testng] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[testng] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[testng] at java.lang.Thread.run(Thread.java:748)
[testng]
[testng] PASSED: test should work
[testng] FAILED: describes
[testng] org.testng.TestNGException:
[testng] Cannot inject @Test annotated Method [describes] with [class java.lang.String, interface kotlin.jvm.functions.Function1].
[testng] For more information on native dependency injection please refer to http://testng.org/doc/documentation-main.html#native-dependency-injection
[testng] at org.testng.internal.Parameters.checkParameterTypes(Parameters.java:407)
[testng] at org.testng.internal.Parameters.createParametersForMethod(Parameters.java:356)
[testng] at org.testng.internal.Parameters.createParameters(Parameters.java:635)
[testng] at org.testng.internal.Parameters.handleParameters(Parameters.java:769)
[testng] at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:49)
[testng] at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:37)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:923)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
[testng] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[testng] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[testng] at java.lang.Thread.run(Thread.java:748)
[testng]
[testng] FAILED: xdescribes
[testng] org.testng.TestNGException:
[testng] Cannot inject @Test annotated Method [xdescribes] with [class java.lang.String, interface kotlin.jvm.functions.Function1].
[testng] For more information on native dependency injection please refer to http://testng.org/doc/documentation-main.html#native-dependency-injection
[testng] at org.testng.internal.Parameters.checkParameterTypes(Parameters.java:407)
[testng] at org.testng.internal.Parameters.createParametersForMethod(Parameters.java:356)
[testng] at org.testng.internal.Parameters.createParameters(Parameters.java:635)
[testng] at org.testng.internal.Parameters.handleParameters(Parameters.java:769)
[testng] at org.testng.internal.ParameterHandler.handleParameters(ParameterHandler.java:49)
[testng] at org.testng.internal.ParameterHandler.createParameters(ParameterHandler.java:37)
[testng] at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:923)
[testng] at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
[testng] at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
[testng] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[testng] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[testng] at java.lang.Thread.run(Thread.java:748)
From @skinny85 investigation this happens only when you run TestNG, passing it a package name (but it works fine if you pass the class names directly).
The proposed workaround is to add another test listener for TestNG, with the following content:
Examples of errors:
From @skinny85 investigation this happens only when you run TestNG, passing it a package name (but it works fine if you pass the class names directly).
The proposed workaround is to add another test listener for TestNG, with the following content: