3

I want to call a feature file with 3 arguments, 1 st argument to create entity with that name and rest of 2 arguments to verify created entity has desired values for particular fields. How can I do this in Karate??

1 Answer 1

4

You can keep all the input in one JSON and pass it to your feature as mentioned in this documentation.

Calling other features

Feature: main 
 Scenario: 
  * def result = call read('myfeature.feature') { createEntity: 'value', arg1: 'arg1Value',arg2: 'arg2Value'} 

Inside your called feature you can directly access the values by the key that you used in your JSON.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.