2

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

VS 2013,MSTest/Test Explorer, Specflow and specrun

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.

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.

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.

imk048
  • 21
  • 3

1 Answers1

1

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

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)

Sam Holder
  • 32,535
  • 13
  • 101
  • 181
  • Thanks for the reply......I have been through nearly all the videos and docs available online already and they all tell about how to run scenarios in parallel that spread across various feature files but running multiple feature files in parallel is a different thing where one thread restricts to one feature file only. I have done this using java with jbehave where i executed multiple stories in parallel and each story having multiple scenarios inside. – imk048 Oct 12 '15 at 17:55
  • Specflow is a unit test generation tool. Something else must run the tests. As currently specflow is not thread safe any test runner must use app domain isolation. Ncrunch's runner will run the tests in parallel. The changes in v2 will make specflow thread safe so that the tests can more easily be run in parallel. Sounds like you will have to wait until the general release of v2, or start using the beta version. You can get the latest CI build from the AppVeyor nuget feed. I'll look up the URL when I'm back at a computer and not on my phone. Although you can find it in one of my other answers – Sam Holder Oct 12 '15 at 18:17