Closed robsonpolicarpo closed 6 years ago
Yes, you should be able to use it with Groovy.
In your build.gradle.
testCompile 'io.github.prashant-ramcharan:courgette-jvm:2.4.3'
testCompile group: 'io.cucumber', name: 'cucumber-groovy', version: '2.0.1'
You can also refer to https://github.com/prashant-ramcharan/courgette-jvm/issues/36#issuecomment-377647767
Thank you @prashant-ramcharan this issue that you linked help me a lot
Glad this helped you @robsonpolicarpo
I tried but throw this exception:
cucumber.runtime.CucumberException: java.lang.NoSuchMethodException: cucumber.runtime.groovy.GroovyBackend.(cucumber.runtime.io.ResourceLoader, io.cucumber.stepexpression.TypeRegistry)
at cucumber.runtime.Reflections.newInstance(Reflections.java:53) at cucumber.runtime.Reflections.instantiateSubclasses(Reflections.java:35) at cucumber.runtime.Runtime.loadBackends(Runtime.java:89) at cucumber.runtime.Runtime.(Runtime.java:42)
at courgette.runtime.CourgetteFeatureLoader.createRuntime(CourgetteFeatureLoader.java:60)
at courgette.runtime.CourgetteFeatureLoader.(CourgetteFeatureLoader.java:30)
at courgette.api.junit.Courgette.(Courgette.java:36)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.junit.internal.builders.AnnotatedBuilder.buildRunner(AnnotatedBuilder.java:104)
at org.junit.internal.builders.AnnotatedBuilder.runnerForClass(AnnotatedBuilder.java:86)
at org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:59)
at org.junit.internal.builders.AllDefaultPossibilitiesBuilder.runnerForClass(AllDefaultPossibilitiesBuilder.java:26)
at org.junit.runners.model.RunnerBuilder.safeRunnerForClass(RunnerBuilder.java:59)
at org.junit.internal.requests.ClassRequest.getRunner(ClassRequest.java:33)
at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:49)
at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47)
at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242)
at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70)
Caused by: java.lang.NoSuchMethodException: cucumber.runtime.groovy.GroovyBackend.(cucumber.runtime.io.ResourceLoader, io.cucumber.stepexpression.TypeRegistry)
at java.lang.Class.getConstructor0(Class.java:3082)
at java.lang.Class.getConstructor(Class.java:1825)
at cucumber.runtime.Reflections.newInstance(Reflections.java:45)
... 20 more