Closed juanfelipemontoyac closed 1 year ago
@juanfelipemontoyac never seen this before sounds very specific to your environment. can reopen if you follow this process: https://github.com/karatelabs/karate/wiki/How-to-Submit-an-Issue
Hi @ptrthomas ! Yes, it's a very specific need, but I managed to find the error, that's why I closed the issue. The problem was in the configuration that I had done for the gradle run task, I just put a default configuration and it works fine!
@juanfelipemontoyac oh okay, glad it works !
All the best! I am currently developing an api in Java with Javalin, Reactor-core and Guice. What my api does is expose an endpoint to run some Karate tests. Because of this, we had to move the Karate folder that was normally found in Test to the Main Folder in order to call it from a main class: Project structure: -src --main ---java ----com.myproject -----controllers ------Controller.java -----Main.java ----features -----Scenario.feature -----karate-config.js The way I'm trying to call the karate tests from the Controller.java class is as follows:
This implementation works when I manually run the Main.java class, but when running the app with gradle run I get this error:
The versions of karate and cucumber that I am using are:
I tried to set the environment variable of js.ecmascript-version=11 but it didn't work
Is there any specific configuration that needs to be taken into account for this to work with the gradle run command?