Run a single scenario in karate

2019-07-26 09:07发布

问题:

To test a specific feature in karate i run this command:

mvn test -Dkarate.options="classpath:myfeature.feature"

there is a way to run a single scenario defined into a feature?

Thanks, Lorenzo

回答1:

Yes, you can via tags: https://github.com/intuit/karate#tags

Also note that you can run a scenario by name, for e.g. if the name is "first":

mvn test -Dkarate.options="classpath:myfeature.feature --name ^first$" 

And if you use IntelliJ - you can right click and do the above.



标签: karate