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

Dispose TestThread-Container correctly #135

Merged
merged 6 commits into from
May 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
* Fix: StackOverflowException when using `[StepArgumentTransformation]` with same input and output type, for example string (#71)
* Fix: Autofac without hook does not run GlobalDependencies (#127)
* Fix: Reqnroll.Autofac shows wrongly ambiguous step definition (#56)
* Fix: Dispose objects registred in test thread container at the end of test execution (#123)

# v1.0.1 - 2024-02-16

Expand Down
1 change: 1 addition & 0 deletions Reqnroll/ITestRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public interface ITestRunner
string TestWorkerId { get; }
FeatureContext FeatureContext { get; }
ScenarioContext ScenarioContext { get; }
ITestThreadContext TestThreadContext { get; }

void InitializeTestRunner(string testWorkerId);

Expand Down
1 change: 1 addition & 0 deletions Reqnroll/Infrastructure/ITestExecutionEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ public interface ITestExecutionEngine
{
FeatureContext FeatureContext { get; }
ScenarioContext ScenarioContext { get; }
ITestThreadContext TestThreadContext { get; }

Task OnTestRunStartAsync();
Task OnTestRunEndAsync();
Expand Down
12 changes: 4 additions & 8 deletions Reqnroll/TestRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,11 @@ public TestRunner(ITestExecutionEngine executionEngine)
_executionEngine = executionEngine;
}

public FeatureContext FeatureContext
{
get { return _executionEngine.FeatureContext; }
}
public FeatureContext FeatureContext => _executionEngine.FeatureContext;

public ScenarioContext ScenarioContext
{
get { return _executionEngine.ScenarioContext; }
}
public ScenarioContext ScenarioContext => _executionEngine.ScenarioContext;

public ITestThreadContext TestThreadContext => _executionEngine.TestThreadContext;

public async Task OnTestRunStartAsync()
{
Expand Down
Loading