Closed digoo closed 3 years ago
one line change: var Common = karate.call(true, 'classpath:routine/routineTest.feature');
refer docs: https://github.com/intuit/karate#call-vs-read see 8the row
Thank you Peter for pointing to the missing detail!
I have tried with karate.callSingle()
but it seems to not work. It's that designed to work that way? If not I could try to include this option there too I would just need your help to point a headstart on the code for me. Thank you once again.
@digoo not designed that way. I think it is fine as it is. if you need to pass any variables, do it explicitly:
karate.callSingle('some.feature', { some: 'value' });
File: varAtJS.zip Could be related to #1322 #1327 #1280 but not duplicate as far I have tested.
It happened on releases: 0.9.5 and 0.9.6 and with develop branch. It used to work about ~20 days ago with develop branch.
It's a simple test:
Where we have at karate-config.js a common routine file being loaded and the var we want to log:
And the common routine file has a JS function trying to read the env variable:
Then it fails with: