Closed anandprasathm closed 3 years ago
Are you running in VS itself or via CLI? Did you make sure the .runsettings are used ?
(in VS, menu> test > test settings > select test settings file)
Are your tests in multiple classes or just one single? Did you enable the ' run tests in parallel' button in the VS test explorer?
@SamJongenelen Thanks for getting back to me on this. I am running the tests on Visual Studio and i have .runsettings file configured as well. I have also enabled 'Run Tests in parallel' button as well. Since, i am using Specflow, all my tests start and ends in Hook class. Is there anything else that i am missing?
Thanks in Advance.
@anandprasathm You have worker set to 0. Is this limiting it? We execute in the SpecFlow 3 Test Suite the tests on 4 threads and they are working.
@SabotageAndi I have set the workers to 4 but still my tests are running one by one. I have added the project files in the below clone URL. Could you please have a look at this and help me with my parallel execution? https://github.com/anandprasathm/MsTestV2.git
Thanks.
@anandprasathm If you have the problem with SpecFlow 3, I will have a look at it. We are about to release it in the next days. No time to analyse this in an old version.
@SabotageAndi Thanks. I will check the same on Specflow version 3 and will come back if the issue still persists.
@SabotageAndi I am also working in specflow facing issue in paralel execution not aware how to set runsetting and how to setup parallelize attribute. I am executing tests using command line .
Please help me with proper steps if any.
@vaibhavvjy I would recommend for you to get to know the mstest test engine/runners/settings/parallelism using plain unittests before moving to Specflow unittests.
Any progress on this issue? I'm not able to get it working either..
@SabotageAndi , With the current Specflow Version (3 and above) and MSTest V2, now i can able to run my Specflow Tests on Parallel.
But intermittently, i am getting the below error on the AfterStep of the last step of the testcase
System.ArgumentException: 'An item with the same key has already been added.'
Could you please help to resolve this?
@anandprasathm please open a new issue for this.
Original issue is solved => closing this one.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Specflow Parallel Execution using MsTest
SpecFlow Version:
Used Test Runner
Version number:
Visual Studio Version
Are the latest Visual Studio updates installed?
.NET Framework:
Test Execution Method:
<SpecFlow> Section in app.config
Issue Description
Hi Friends, I am trying to run my Specflow Tests in Parallel using MsTest V2. Below is the Test Runner file that i am using to run my Specflow Tests in Parallel. I have this configured on Test Settings as well but still my tests are running one by one. Not sure if i am missing some other settings. Could someone please assist me on this?
Test Runner File:
Thanks in Advance.