I am trying to calling a feature file with a javascript function. However, I have noticed sometimes exception "org.graalvm.polyglot.PolyglotException: java.io.FileNotFoundException" as it is trying to look in a different location path
here is what I am trying,
* def jsonPathExists =
"""
function(personApplicant)
{
if ('BABLProperties' in personApplicant)
{ karate.call('../reusableFeatures/restMethods/PatchRequestHelper.feature@patchLoanConditionsGeneric',{payload:RequestBody})
}
}
"""
* def pathExists = jsonPathExists(personApplicant, RequestBody)
Below is the exception: If we notice the exception, it is trying to look into different path location. Can you advise if I am following anything wrong? Also I notice this sometime it does work for a different script with similar pattern.
org.graalvm.polyglot.PolyglotException: java.io.FileNotFoundException: C:\Users\ADMZN13\Workspace\benbroker_apitest\target\test-classes\loanApplicationApi\Patch..\reusableFeatures\restMethods\PatchRequestHelper.feature (The system cannot find the path specified)
- com.intuit.karate.resource.FileResource.getStream(FileResource.java:98)