Unable to use read('classpath:') when running tests with standalone karate.jar

前端 未结 1 964
故里飘歌
故里飘歌 2020-12-02 01:14

I am attempting to execute my tests using the karate stand-alone jar. Throughout my project, I use the read(\'classpath:\') when locating files.

Howeve

相关标签:
1条回答
  • 2020-12-02 02:00

    Can you try the ZIP release and if you open the karate batch file you will see this:

    java -cp karate.jar:. com.intuit.karate.Main $*
    

    So the trick to setting a custom classpath is to use the com.intuit.karate.Main entry point and in the above example the current dir is also added to the classpath.

    It would be great if you try the current RC version (0.9.5.RC3) to ensure we have everything working as expected.

    For more information, see this part of the docs: https://github.com/intuit/karate/tree/develop/karate-netty#custom-classpath

    0 讨论(0)
提交回复
热议问题