-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gradle resource are copied to resource/test not classes/test #737
Comments
sounds like a gradle thing, marking this ticket as "help wanted" as we use maven |
Could it be an option for you to create a fallback in the 'relative feature file resolving' method? Something like: If don't find the feature file next to the class file, I will try to create a class path lookup for the feature like its done in all the Happy to create a PR... |
I don't remember the details - but that routine has been through a few iterations to get resources within JAR files to work #520 not able to follow what you mean about the "behaves different", maybe you can add a test here: https://github.com/intuit/karate/blob/master/karate-core/src/test/java/com/intuit/karate/RunnerTest.java - and yes a PR sounds good |
I created a PR #739 to fix the gradle build in |
I created a Test in my personal repository because it's tricky to reproduce the behavior with maven. I hope this test explains the problem: Here is a naive solution to the problem: |
@peterquiel it looks ok to me, you can go ahead with a PR if it doesn't break any existing tests. |
Done: #764 |
…ng-with-gradle #737 - relative resource loading with gradle
released 0.9.3 |
The following configuration form the documentation ensures, that resource files in source directory are respected
With this configuration the resource files are copied to
build/resource/test
folder where they are not picked every relative to class method.Changing the resource output directory to
build/classes/java/test
solves this problem.I personally find it surprising that the
com.intuit.karate.Runner#runFeature(java.lang.Class, java.lang.String, java.util.Map<java.lang.String,java.lang.Object>, boolean)
and
com.intuit.karate.Runner#runFeature(java.lang.String, java.util.Map<java.lang.String,java.lang.Object>, boolean)
behaves different.The text was updated successfully, but these errors were encountered: