2

For our project requirement we have to run the feature file using 50 users . For now I am able to run using one user which is configured in the karate.config file. I need to configure these 50 users in the config file and run the same feature file for all 50 users. Looking for a way to configure all users in one config file and run the feature file.

1 Answer 1

5

Here's my suggestion.

Don't overload your config file like this.

Use a JSON file with an array of users.

Now you can read this JSON file from any feature using the read syntax.

And you can use Karate's built-in looping capability to do what you need: https://github.com/intuit/karate#data-driven-features

* def users = read('users.json')
* def result = call read('user-test.feature') users
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.