使用specflow/specrun时如何并行运行特征文件? [英] How to run feature files in parallel when using specflow/specrun?

查看:176
本文介绍了使用specflow/specrun时如何并行运行特征文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在实施一个项目以进行概念验证,这是我正在使用的内容:

I am implementing a project for the proof of concept and here is what i am using:

VS 2013,MSTest/Test Explorer,Specflow和specrun

VS 2013,MSTest/Test Explorer, Specflow and specrun

我创建了3个specflow功能文件,每个文件都有自己的不同场景集.当我从测试资源管理器运行这些测试时,我可以成功地看到每个功能文件中一个接一个地运行的所有场景,这绝对没问题.

I have created 3 specflow feature files, each having it's own sets of different scenarios. When I run these tests from test explorer i can successfully see all the scenarios in each feature file running one by one and that's absolutely fine.

接下来,我要并行运行所有3个功能文件.有没有办法做到这一点?我所有的功能文件都是彼此完全独立的,并且具有各自不同的场景.

Next, I want to run all the 3 feature files in parallel. Is there a way to do this? All my feature files are completely independent from each other and have their own different set of scenarios.

我看到的链接很少,仅告诉您如何使用Default.srprofile并行运行方案,而在并行运行的功能文件中找不到任何内容.

I have seen few links that only tells how to run scenarios in parallel by using Default.srprofile but can't find anything on running feature files in parallel.

推荐答案

specrun重复记录表示这是可行的,并链接到此视频以展示其操作方式.

The specrun doucumentation says this is possible and links to this video to show how it is done.

我没有使用specrun,因此无法评论其有效性,但是我知道在v2分支的该区域中已经完成了一些工作,这将使specflow线程安全,并允许与任何支持并行运行测试的测试运行器(NUnit3,xUnit2等)并行执行

I've not used specrun, so can't comment on its effectiveness, but I do know that some work has been done in this area in the v2 branch which will make specflow thread safe and allow parallel execution with any test runner that supports running tests in parallel (NUnit3, xUnit2 etc)

这篇关于使用specflow/specrun时如何并行运行特征文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆