Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallel execution using Mstest+reqnroll #116

Closed
sampath-ganesan opened this issue May 2, 2024 · 7 comments
Closed

Parallel execution using Mstest+reqnroll #116

sampath-ganesan opened this issue May 2, 2024 · 7 comments
Labels
by design We planned it to work that way

Comments

@sampath-ganesan
Copy link

Reqnroll Version

1.0.1

Which test runner are you using?

MSTest

Test Runner Version Number

MsTest.TestAdapter 3.3.1

.NET Implementation

.NET 8.0

Test Execution Method

Visual Studio Test Explorer

Content of reqnroll.json configuration file

No response

Issue Description

I am trying to run scenarios in parallel execution using mstest while doing that i am facing few issues,

  1. The previous ScenarioStepContext was already disposed, The previous ScenarioContext was already disposed.
  2. while running in 2 threads scenario step details are mixed up with other threads
  3. step name is getting mixed up on the extend report, for some

Steps to Reproduce

  1. set up mstest project with reqnroll and add few basic scenarios and also use extend report
  2. set Parallelize via .runsettings
  3. use StepContext.StepInfo

Note: I also tried

private readonly ScenarioContext scenarioContext;

public SpecflowHooks(ScenarioContext scenarioContext)
{
this.scenarioContext = scenarioContext;
}

And

ScenarioContext.Current.ScenarioInfo

Link to Repro Project

No response

@sampath-ganesan sampath-ganesan added the bug Something isn't working label May 2, 2024
@ajeckmans
Copy link
Contributor

Only feature level parallelization is supported for mstest. See also https://docs.reqnroll.net/latest/execution/parallel-execution.html

@sampath-ganesan
Copy link
Author

is there any plan to add this feature which is scenario level parallel execution?

@ajeckmans
Copy link
Contributor

Nothing that is concrete though it is definitely something that is kept in mind.

@sampath-ganesan
Copy link
Author

thanks for the info

@gasparnagy
Copy link
Contributor

@sampath-ganesan please also see my comment at #114. I recommend creating an idea discussion item for this.

I close this as by design, we can track this at the discussion item.

@gasparnagy gasparnagy added by design We planned it to work that way and removed bug Something isn't working labels May 2, 2024
@sampath-ganesan
Copy link
Author

i am able to open multiple browser with ThreadLocal and again that ScenarioContext is not supporting that ThreadLocal so its getting disposed after first scenario completes on that thread

@gasparnagy
Copy link
Contributor

@sampath-ganesan please make a separate issue for that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
by design We planned it to work that way
Projects
None yet
Development

No branches or pull requests

3 participants