Does the callonce function executes the feature again if i use use in this function multiple times in different features?

百般思念 提交于 2019-12-24 11:58:05

问题


I have multiple feature files in my project. One of the feature file creates tokens. I want to call this feature only once at the start of the test and then use the tokens in the other feature without executing the token feature again and again.

Can someone please help me with this ?


回答1:


Look at callSingle() in karate-config.js and please refer the docs: https://github.com/intuit/karate#hooks

var result = karate.callSingle('classpath:tokens.feature');


来源:https://stackoverflow.com/questions/54227040/does-the-callonce-function-executes-the-feature-again-if-i-use-use-in-this-funct

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