Karate — Parallel execution Failing

僤鯓⒐⒋嵵緔 提交于 2019-12-12 18:19:36

问题


I have observed that when I am running my tests (feature files) in maven build with Runner.parallel(getClass(), 1); it is working fine but when I am increasing number of thread like Runner.parallel(getClass(), 5); it start failing because it is executing all scenarios in parallel which is available in feature file. Scenarios are dependent on each other which are failing because which scenario need to execute in last executing in first.

Please suggest me some option which run all feature file in parallel but not run scenarios in parallel which available in feature file.


回答1:


https://github.com/intuit/karate#parallelfalse

If you use @parallel=false on each feature where scenarios cannot be played in parallel, it'll work. But scenarios should be played in any order and not be dependent on each other. Maybe what you call scenarios shouldn't be split in the first place?

More information about script structure : https://github.com/intuit/karate#script-structure



来源:https://stackoverflow.com/questions/54538060/karate-parallel-execution-failing

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!