diff --git a/CHANGELOG.md b/CHANGELOG.md
index b57570741..bdd1a1dc1 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,7 @@
# [vNext]
+* Reqnroll.Verify: Support for Verify v24 (Verify.Xunit v24.2.0) for .NET 4.7.2+ and .NET 6.0+. For earlier versions of Verify or for .NET 4.6.2, use the latest 2.0.3 version of the plugin that is compatible with Reqnroll v2.*. (#151)
+
## Improvements:
* Update [versioning policy for plugins](https://docs.reqnroll.net/latest/installation/compatibility.html#versioning-policy) and set plugin dependencies accordingly (#160)
@@ -37,7 +39,7 @@
## Bug fixes:
* Fix: User code namespaces that included "Reqnroll" within them caused the code generation to fail (#44)
-* Fix: Dependencies of [BeforeTestRun] / [AfterTestRun] hooks are wonrly resolved from the test thread context instead of the test run (global) context instead (#58)
+* Fix: Dependencies of [BeforeTestRun] / [AfterTestRun] hooks are wrongly resolved from the test thread context instead of the test run (global) context instead (#58)
* Fix: Cucumber Expressions fail when two enums or two custom types with the same short name (differing namespaces) are used as parameters (#81)
* Fix: Adding `@ignore` to an Examples block generates invalid code for NUnit v3+ (#103)
* Fix: `@ignore` attribute is not inherited to the scenarios from Rule (#111)
@@ -45,7 +47,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)
+* Fix: Dispose objects registered in test thread container at the end of test execution (#123)
# v1.0.1 - 2024-02-16
diff --git a/Plugins/Reqnroll.ExternalData/Reqnroll.ExternalData.ReqnrollPlugin/Reqnroll.ExternalData.ReqnrollPlugin.csproj b/Plugins/Reqnroll.ExternalData/Reqnroll.ExternalData.ReqnrollPlugin/Reqnroll.ExternalData.ReqnrollPlugin.csproj
index bbb4452b3..d05099449 100644
--- a/Plugins/Reqnroll.ExternalData/Reqnroll.ExternalData.ReqnrollPlugin/Reqnroll.ExternalData.ReqnrollPlugin.csproj
+++ b/Plugins/Reqnroll.ExternalData/Reqnroll.ExternalData.ReqnrollPlugin/Reqnroll.ExternalData.ReqnrollPlugin.csproj
@@ -14,7 +14,7 @@
-
+
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/AssemblyHooks.cs b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/AssemblyHooks.cs
deleted file mode 100644
index 36ef5d82a..000000000
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/AssemblyHooks.cs
+++ /dev/null
@@ -1,33 +0,0 @@
-//
-#pragma warning disable
-
-using System.CodeDom.Compiler;
-using global::System.Runtime.CompilerServices;
-using System.Threading.Tasks;
-
-[assembly: global::Xunit.TestFramework("Reqnroll.xUnit.ReqnrollPlugin.XunitTestFrameworkWithAssemblyFixture", "Reqnroll.xUnit.ReqnrollPlugin")]
-[assembly: global::Reqnroll.xUnit.ReqnrollPlugin.AssemblyFixture(typeof(global::XUnitAssemblyFixture))]
-
-[GeneratedCode("Reqnroll", "3.10.3-beta")]
-public class XUnitAssemblyFixture : global::Xunit.IAsyncLifetime
-{
- [MethodImpl(MethodImplOptions.NoInlining)]
- public async Task InitializeAsync()
- {
- var currentAssembly = typeof(XUnitAssemblyFixture).Assembly;
- await global::Reqnroll.TestRunnerManager.OnTestRunStartAsync(currentAssembly);
- }
-
- [MethodImpl(MethodImplOptions.NoInlining)]
- public async Task DisposeAsync()
- {
- var currentAssembly = typeof(XUnitAssemblyFixture).Assembly;
- await global::Reqnroll.TestRunnerManager.OnTestRunEndAsync(currentAssembly);
- }
-}
-
-[global::Xunit.CollectionDefinition("ReqnrollNonParallelizableFeatures", DisableParallelization = true)]
-public class ReqnrollNonParallelizableFeaturesCollectionDefinition
-{
-}
-#pragma warning restore
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest.csproj b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest.csproj
index af2dbacef..6a3f0615b 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest.csproj
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest/Reqnroll.Verify.ReqnrollPlugin.IntegrationTest.csproj
@@ -1,7 +1,7 @@
-
-
+
+ net8.0
@@ -9,47 +9,40 @@
-
-
-
-
+
+
+
+ allruntime; build; native; contentfiles; analyzers
-
+ allruntime; build; native; contentfiles; analyzers
-
-
+
+
-
-
-
- <_VerifyGeneratorPluginFramework Condition=" '$(MSBuildRuntimeType)' == 'Core'">netstandard2.0
- <_VerifyGeneratorPluginFramework Condition=" '$(MSBuildRuntimeType)' != 'Core'">net462
-
+
-
-
-
+
+
-
-
+
-
+
-
+
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.ReqnrollPlugin.csproj b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.ReqnrollPlugin.csproj
index 7271dcf11..e2e9ecfe5 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.ReqnrollPlugin.csproj
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.ReqnrollPlugin.csproj
@@ -1,21 +1,21 @@
- net462;netstandard2.0
- $(MSBuildThisFileDirectory)Reqnroll.Verify.nuspec
+ net472;net6.0$(Reqnroll_KeyFile)$(Reqnroll_EnableStrongNameSigning)$(Reqnroll_PublicSign)
+
true
+ $(MSBuildThisFileDirectory)Reqnroll.Verify.nuspectrue
-
-
+
-
+
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.nuspec b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.nuspec
index a21debbc6..1c742d3c1 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.nuspec
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/Reqnroll.Verify.nuspec
@@ -13,17 +13,17 @@
images\reqnroll-icon.pngfalseBSD-3-Clause
- reqnroll externaldata json
+ reqnroll verify$copyright$
-
+
-
+
-
+
-
+
@@ -31,11 +31,8 @@
-
-
-
-
-
+
+
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyDecorator.cs b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyDecorator.cs
deleted file mode 100644
index 48b58ab0e..000000000
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyDecorator.cs
+++ /dev/null
@@ -1,25 +0,0 @@
-using Reqnroll.Generator;
-using Reqnroll.Generator.CodeDom;
-using Reqnroll.Generator.UnitTestConverter;
-
-namespace Reqnroll.Verify.ReqnrollPlugin;
-
-public class VerifyDecorator : ITestClassDecorator
-{
- private readonly CodeDomHelper _codeDomHelper;
-
- public VerifyDecorator(CodeDomHelper codeDomHelper)
- {
- _codeDomHelper = codeDomHelper;
- }
-
- public int Priority { get; } = 0;
-
- public bool CanDecorateFrom(TestClassGenerationContext generationContext) => true;
-
- public void DecorateFrom(TestClassGenerationContext generationContext)
- {
- _codeDomHelper.AddAttribute(generationContext.TestClass, "UsesVerify");
-
- }
-}
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyGeneratorPlugin.cs b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyGeneratorPlugin.cs
deleted file mode 100644
index e965fd810..000000000
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyGeneratorPlugin.cs
+++ /dev/null
@@ -1,22 +0,0 @@
-using Reqnroll.Verify.ReqnrollPlugin;
-using Reqnroll.Generator.Plugins;
-using Reqnroll.Generator.UnitTestConverter;
-using Reqnroll.Infrastructure;
-using Reqnroll.UnitTestProvider;
-
-[assembly:GeneratorPlugin(typeof(VerifyGeneratorPlugin))]
-
-namespace Reqnroll.Verify.ReqnrollPlugin
-{
- public class VerifyGeneratorPlugin : IGeneratorPlugin
- {
- public void Initialize(GeneratorPluginEvents generatorPluginEvents, GeneratorPluginParameters generatorPluginParameters,
- UnitTestProviderConfiguration unitTestProviderConfiguration)
- {
- generatorPluginEvents.RegisterDependencies += (sender, args) =>
- {
- args.ObjectContainer.RegisterTypeAs("verify");
- };
- }
- }
-}
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyRuntimePlugin.cs b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyRuntimePlugin.cs
index ee6e6bd32..d9bba2ed3 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyRuntimePlugin.cs
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/VerifyRuntimePlugin.cs
@@ -1,10 +1,10 @@
using System.Collections;
using System.IO;
-using Reqnroll.Verify.ReqnrollPlugin;
-using Reqnroll;
using Reqnroll.Plugins;
using Reqnroll.UnitTestProvider;
+using Reqnroll.Verify.ReqnrollPlugin;
using VerifyTests;
+using VerifyXunit;
[assembly: RuntimePlugin(typeof(VerifyRuntimePlugin))]
@@ -28,7 +28,7 @@ private void RuntimePluginTestExecutionLifecycleEvents_BeforeScenario(object sen
var scenarioContext = e.ObjectContainer.Resolve();
var featureContext = e.ObjectContainer.Resolve();
- VerifierSettings.DerivePathInfo(
+ Verifier.DerivePathInfo(
(sourceFile, projectDirectory, type, method) =>
{
string scenarioInfoTitle = scenarioContext.ScenarioInfo.Title;
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.props b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.props
index 2d571f8ac..be788a84c 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.props
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.props
@@ -1,5 +1,9 @@
-
-
-
+
+
+ %(Filename)%(Extension)
+ PreserveNewest
+ False
+
+
\ No newline at end of file
diff --git a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.targets b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.targets
index 1b5945aaf..b89a84084 100644
--- a/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.targets
+++ b/Plugins/Reqnroll.Verify/Reqnroll.Verify.ReqnrollPlugin/build/Reqnroll.Verify.targets
@@ -1,9 +1,7 @@
- <_VerifyGeneratorPluginFramework Condition=" '$(MSBuildRuntimeType)' == 'Core'">netstandard2.0
- <_VerifyGeneratorPluginFramework Condition=" '$(MSBuildRuntimeType)' != 'Core'">net462
-
- <_VerifyGeneratorPluginPath>$(MSBuildThisFileDirectory)$(_VerifyGeneratorPluginFramework)\Reqnroll.Verify.ReqnrollPlugin.dll
-
+ <_VerifyRuntimePlugin Condition=" '$(TargetFrameworkIdentifier)' == '.NETFramework' ">net472
+ <_VerifyRuntimePlugin Condition=" '$(TargetFrameworkIdentifier)' != '.NETFramework' ">net6.0
+ <_VerifyRuntimePluginPath>$(MSBuildThisFileDirectory)..\lib\$(_VerifyRuntimePlugin)\Reqnroll.Verify.ReqnrollPlugin.dll
diff --git a/Tests/Reqnroll.GeneratorTests/Reqnroll.GeneratorTests.csproj b/Tests/Reqnroll.GeneratorTests/Reqnroll.GeneratorTests.csproj
index e89529de3..4c7d4eff3 100644
--- a/Tests/Reqnroll.GeneratorTests/Reqnroll.GeneratorTests.csproj
+++ b/Tests/Reqnroll.GeneratorTests/Reqnroll.GeneratorTests.csproj
@@ -31,12 +31,12 @@
-
-
+
+ allruntime; build; native; contentfiles; analyzers
-
+ allruntime; build; native; contentfiles; analyzers
diff --git a/Tests/Reqnroll.PluginTests/ExternalData/CsvLoaderTests.cs b/Tests/Reqnroll.PluginTests/ExternalData/CsvLoaderTests.cs
index 4e66d7c5b..39b8d2bce 100644
--- a/Tests/Reqnroll.PluginTests/ExternalData/CsvLoaderTests.cs
+++ b/Tests/Reqnroll.PluginTests/ExternalData/CsvLoaderTests.cs
@@ -22,7 +22,7 @@ public void Can_read_simple_csv_file()
{
var sut = CreateSut();
var result = sut.LoadDataSource(_productsSampleFilePath, null);
-
+
Assert.True(result.IsDataTable);
Assert.Equal(3, result.AsDataTable.Items.Count);
Assert.Equal("Chocolate", result.AsDataTable.Items[0].Fields["product"].AsString());
@@ -53,7 +53,7 @@ public void Can_handle_relative_path()
{
var sut = CreateSut();
var result = sut.LoadDataSource(
- Path.GetFileName(_productsSampleFilePath),
+ Path.GetFileName(_productsSampleFilePath),
SampleFeatureFilePathInSampleFileFolder);
Assert.True(result.IsDataTable);
@@ -63,8 +63,8 @@ public void Can_handle_relative_path()
public void Can_handle_invalid_path()
{
var sut = CreateSut();
-
- Assert.Throws(() =>
+
+ Assert.Throws(() =>
sut.LoadDataSource(
"no-such-file.csv",
SampleFeatureFilePathInSampleFileFolder));
@@ -76,7 +76,7 @@ public void Can_handle_invalid_csv_file_format()
_productsSampleFilePath = Path.Combine(SampleFilesFolder, "products-invalid.csv");
var sut = CreateSut();
- Assert.Throws(() =>
+ Assert.Throws(() =>
sut.LoadDataSource(_productsSampleFilePath, null));
}
@@ -86,11 +86,11 @@ public void Can_handle_empty_csv_with_header_only()
_productsSampleFilePath = Path.Combine(SampleFilesFolder, "products-empty.csv");
var sut = CreateSut();
-
+
var result = sut.LoadDataSource(_productsSampleFilePath, null);
Assert.True(result.IsDataTable);
- Assert.Equal(0, result.AsDataTable.Items.Count);
+ Assert.Empty(result.AsDataTable.Items);
}
}
}
diff --git a/Tests/Reqnroll.PluginTests/Reqnroll.PluginTests.csproj b/Tests/Reqnroll.PluginTests/Reqnroll.PluginTests.csproj
index 9547d9520..a954362ef 100644
--- a/Tests/Reqnroll.PluginTests/Reqnroll.PluginTests.csproj
+++ b/Tests/Reqnroll.PluginTests/Reqnroll.PluginTests.csproj
@@ -25,12 +25,12 @@
-
-
+
+ allruntime; build; native; contentfiles; analyzers
-
+ allruntime; build; native; contentfiles; analyzers
diff --git a/Tests/Reqnroll.RuntimeTests/Bindings/CucumberExpressions/CucumberExpressionIntegrationTests.cs b/Tests/Reqnroll.RuntimeTests/Bindings/CucumberExpressions/CucumberExpressionIntegrationTests.cs
index c81fb54aa..4c140d512 100644
--- a/Tests/Reqnroll.RuntimeTests/Bindings/CucumberExpressions/CucumberExpressionIntegrationTests.cs
+++ b/Tests/Reqnroll.RuntimeTests/Bindings/CucumberExpressions/CucumberExpressionIntegrationTests.cs
@@ -195,7 +195,7 @@ private async Task PerformStepExecution(string methodName, strin
}
[Fact]
- public async void Should_match_step_with_simple_cucumber_expression()
+ public async Task Should_match_step_with_simple_cucumber_expression()
{
var expression = "there is something";
var stepText = "there is something";
@@ -207,7 +207,7 @@ public async void Should_match_step_with_simple_cucumber_expression()
}
[Fact]
- public async void Should_match_step_with_parameterless_cucumber_expression()
+ public async Task Should_match_step_with_parameterless_cucumber_expression()
{
var expression = "there is/are something(s) here \\/ now";
var stepText = "there are something here / now";
@@ -219,7 +219,7 @@ public async void Should_match_step_with_parameterless_cucumber_expression()
}
[Fact]
- public async void Should_match_step_with_string_parameter_using_apostrophe()
+ public async Task Should_match_step_with_string_parameter_using_apostrophe()
{
var expression = "there is a user {string} registered";
var stepText = "there is a user 'Marvin' registered";
@@ -232,7 +232,7 @@ public async void Should_match_step_with_string_parameter_using_apostrophe()
}
[Fact]
- public async void Should_match_step_with_string_parameter_using_quotes()
+ public async Task Should_match_step_with_string_parameter_using_quotes()
{
var expression = "there is a user {string} registered";
var stepText = "there is a user \"Marvin\" registered";
@@ -245,7 +245,7 @@ public async void Should_match_step_with_string_parameter_using_quotes()
}
[Fact]
- public async void Should_match_step_with_word_parameter()
+ public async Task Should_match_step_with_word_parameter()
{
var expression = "there is a user {word} registered";
var stepText = "there is a user Marvin registered";
@@ -258,7 +258,7 @@ public async void Should_match_step_with_word_parameter()
}
[Fact]
- public async void Should_match_step_with_int_parameter()
+ public async Task Should_match_step_with_int_parameter()
{
var expression = "I have {int} cucumbers in my belly";
var stepText = "I have 42 cucumbers in my belly";
@@ -271,7 +271,7 @@ public async void Should_match_step_with_int_parameter()
}
[Fact]
- public async void Should_match_step_with_float_parameter()
+ public async Task Should_match_step_with_float_parameter()
{
var expression = "I have {float} cucumbers in my belly";
var stepText = "I have 42.1 cucumbers in my belly";
@@ -284,7 +284,7 @@ public async void Should_match_step_with_float_parameter()
}
[Fact]
- public async void Should_match_step_with_float_parameter_to_double()
+ public async Task Should_match_step_with_float_parameter_to_double()
{
var expression = "I have {float} cucumbers in my belly";
var stepText = "I have 42.1 cucumbers in my belly";
@@ -297,7 +297,7 @@ public async void Should_match_step_with_float_parameter_to_double()
}
[Fact]
- public async void Should_match_step_with_double_parameter()
+ public async Task Should_match_step_with_double_parameter()
{
var expression = "I have {double} cucumbers in my belly";
var stepText = "I have 42.1 cucumbers in my belly";
@@ -310,7 +310,7 @@ public async void Should_match_step_with_double_parameter()
}
[Fact]
- public async void Should_match_step_with_decimal_parameter()
+ public async Task Should_match_step_with_decimal_parameter()
{
var expression = "I have {decimal} cucumbers in my belly";
var stepText = "I have 42.1 cucumbers in my belly";
@@ -323,7 +323,7 @@ public async void Should_match_step_with_decimal_parameter()
}
[Fact]
- public async void Should_match_step_with_float_parameter_to_decimal()
+ public async Task Should_match_step_with_float_parameter_to_decimal()
{
var expression = "I have {float} cucumbers in my belly";
var stepText = "I have 42.1 cucumbers in my belly";
@@ -336,7 +336,7 @@ public async void Should_match_step_with_float_parameter_to_decimal()
}
[Fact]
- public async void Should_match_step_with_joker_parameter()
+ public async Task Should_match_step_with_joker_parameter()
{
var expression = "there is a user {} registered";
var stepText = "there is a user Marvin registered";
@@ -350,7 +350,7 @@ public async void Should_match_step_with_joker_parameter()
// build-in types supported by Reqnroll
[Fact]
- public async void Should_match_step_with_Int32_parameter()
+ public async Task Should_match_step_with_Int32_parameter()
{
var expression = "I have {Int32} cucumbers in my belly";
var stepText = "I have 42 cucumbers in my belly";
@@ -364,7 +364,7 @@ public async void Should_match_step_with_Int32_parameter()
// enum support
[Fact]
- public async void Should_match_step_with_enum_parameter()
+ public async Task Should_match_step_with_enum_parameter()
{
var expression = "I have {SampleColorEnum} cucumbers in my belly";
var stepText = "I have Yellow cucumbers in my belly";
@@ -379,14 +379,14 @@ public async void Should_match_step_with_enum_parameter()
// custom type conversion support
[Fact]
- public async void Should_match_step_with_custom_parameter_with_type_name()
+ public async Task Should_match_step_with_custom_parameter_with_type_name()
{
var expression = "there is a {SampleUser} registered";
var stepText = "there is a user Marvin registered";
var expectedParam = (new SampleUser("Marvin"), typeof(SampleUser));
var methodName = nameof(SampleBindings.StepDefWithCustomClassParam);
IStepArgumentTransformationBinding transformation = new StepArgumentTransformationBinding(
- "user ([A-Z][a-z]+)",
+ "user ([A-Z][a-z]+)",
new RuntimeBindingMethod(typeof(SampleUser).GetMethod(nameof(SampleUser.Create))));
var sampleBindings = await PerformStepExecution(methodName, expression, stepText, new[] { transformation});
@@ -396,14 +396,14 @@ public async void Should_match_step_with_custom_parameter_with_type_name()
[Fact]
- public async void Should_match_step_with_custom_parameter_with_custom_name()
+ public async Task Should_match_step_with_custom_parameter_with_custom_name()
{
var expression = "there is a {user} registered";
var stepText = "there is a user Marvin registered";
var expectedParam = (new SampleUser("Marvin"), typeof(SampleUser));
var methodName = nameof(SampleBindings.StepDefWithCustomClassParam);
IStepArgumentTransformationBinding transformation = new StepArgumentTransformationBinding(
- "user ([A-Z][a-z]+)",
+ "user ([A-Z][a-z]+)",
new RuntimeBindingMethod(typeof(SampleUser).GetMethod(nameof(SampleUser.Create))),
"user");
@@ -413,7 +413,7 @@ public async void Should_match_step_with_custom_parameter_with_custom_name()
}
[Fact]
- public async void Should_match_step_with_customized_built_in_parameter_with_type_name()
+ public async Task Should_match_step_with_customized_built_in_parameter_with_type_name()
{
var expression = "I have {Int32} cucumbers in my belly";
var stepText = "I have forty two cucumbers in my belly";
@@ -429,7 +429,7 @@ public async void Should_match_step_with_customized_built_in_parameter_with_type
}
[Fact]
- public async void Should_match_step_with_customized_built_in_parameter_with_simple_name()
+ public async Task Should_match_step_with_customized_built_in_parameter_with_simple_name()
{
var expression = "I have {int} cucumbers in my belly";
var stepText = "I have forty two cucumbers in my belly";
@@ -445,7 +445,7 @@ public async void Should_match_step_with_customized_built_in_parameter_with_simp
}
[Fact]
- public async void Should_match_step_with_customized_built_in_parameter_without_recursion_string()
+ public async Task Should_match_step_with_customized_built_in_parameter_without_recursion_string()
{
var expression = "there is a user {string} registered";
var stepText = "there is a user 'Marvin' registered";
@@ -462,7 +462,7 @@ public async void Should_match_step_with_customized_built_in_parameter_without_r
}
[Fact]
- public async void Should_match_step_with_customized_built_in_parameter_without_recursion_int32()
+ public async Task Should_match_step_with_customized_built_in_parameter_without_recursion_int32()
{
var expression = "I have {int} cucumbers in my belly";
var stepText = "I have 43 cucumbers in my belly";
@@ -479,7 +479,7 @@ public async void Should_match_step_with_customized_built_in_parameter_without_r
}
[Fact]
- public async void Should_match_step_with_custom_parameter_with_additional_step_arguments()
+ public async Task Should_match_step_with_custom_parameter_with_additional_step_arguments()
{
var expression = "there is a {user} registered";
var stepText = "there is a user Marvin Smith he is 27 years old and 175 height registered";
diff --git a/Tests/Reqnroll.RuntimeTests/Infrastructure/TestExecutionEngineTests.cs b/Tests/Reqnroll.RuntimeTests/Infrastructure/TestExecutionEngineTests.cs
index 16794c835..df03eeb27 100644
--- a/Tests/Reqnroll.RuntimeTests/Infrastructure/TestExecutionEngineTests.cs
+++ b/Tests/Reqnroll.RuntimeTests/Infrastructure/TestExecutionEngineTests.cs
@@ -379,7 +379,7 @@ public async Task Should_cleanup_step_context_after_scenario_block_hook_error()
{
await testExecutionEngine.StepAsync(StepDefinitionKeyword.Given, null, "foo", null, null);
- Assert.True(false, "execution of the step should have failed because of the exeption thrown by the before scenario block hook");
+ Assert.Fail("execution of the step should have failed because of the exeption thrown by the before scenario block hook");
}
catch (Exception)
{
diff --git a/Tests/Reqnroll.RuntimeTests/Reqnroll.RuntimeTests.csproj b/Tests/Reqnroll.RuntimeTests/Reqnroll.RuntimeTests.csproj
index e1972e83a..7374cfe2d 100644
--- a/Tests/Reqnroll.RuntimeTests/Reqnroll.RuntimeTests.csproj
+++ b/Tests/Reqnroll.RuntimeTests/Reqnroll.RuntimeTests.csproj
@@ -25,12 +25,12 @@
-
-
+
+ allruntime; build; native; contentfiles; analyzers
-
+ allruntime; build; native; contentfiles; analyzers
diff --git a/Tests/Reqnroll.Specs/Reqnroll.Specs.csproj b/Tests/Reqnroll.Specs/Reqnroll.Specs.csproj
index 7d8ef45d3..0b24ab993 100644
--- a/Tests/Reqnroll.Specs/Reqnroll.Specs.csproj
+++ b/Tests/Reqnroll.Specs/Reqnroll.Specs.csproj
@@ -43,12 +43,12 @@
-
-
+
+ allruntime; build; native; contentfiles; analyzers
-
+ allruntime; build; native; contentfiles; analyzers
diff --git a/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator.Tests/Reqnroll.TestProjectGenerator.Tests.csproj b/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator.Tests/Reqnroll.TestProjectGenerator.Tests.csproj
index a20db0e0b..26b4a87fd 100644
--- a/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator.Tests/Reqnroll.TestProjectGenerator.Tests.csproj
+++ b/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator.Tests/Reqnroll.TestProjectGenerator.Tests.csproj
@@ -9,8 +9,8 @@
-
-
+
+ allruntime; build; native; contentfiles; analyzers
diff --git a/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator/ProjectBuilder.cs b/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator/ProjectBuilder.cs
index 92f716480..f903fa15b 100644
--- a/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator/ProjectBuilder.cs
+++ b/Tests/TestProjectGenerator/Reqnroll.TestProjectGenerator/ProjectBuilder.cs
@@ -312,11 +312,11 @@ private void ConfigureXUnit()
{
_project.AddNuGetPackage("xunit.core", XUnitPackageVersion);
_project.AddNuGetPackage("xunit.extensibility.core", XUnitPackageVersion,
- new NuGetPackageAssembly("xunit.core, Version=2.4.2.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "net452\\xunit.core.dll"));
+ new NuGetPackageAssembly($"xunit.core, Version={XUnitPackageVersion}.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "net452\\xunit.core.dll"));
_project.AddNuGetPackage("xunit.extensibility.execution", XUnitPackageVersion,
- new NuGetPackageAssembly("xunit.execution.desktop, Version=2.4.2.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "net452\\xunit.execution.desktop.dll"));
+ new NuGetPackageAssembly($"xunit.execution.desktop, Version={XUnitPackageVersion}.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "net452\\xunit.execution.desktop.dll"));
_project.AddNuGetPackage("xunit.assert", XUnitPackageVersion,
- new NuGetPackageAssembly("xunit.assert, Version=2.4.2.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "netstandard1.1\\xunit.assert.dll"));
+ new NuGetPackageAssembly($"xunit.assert, Version={XUnitPackageVersion}.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "netstandard1.1\\xunit.assert.dll"));
_project.AddNuGetPackage("xunit.abstractions", "2.0.3",
new NuGetPackageAssembly("xunit.abstractions, Version=2.0.0.0, Culture=neutral, PublicKeyToken=8d05b1bb7a6fdb6c", "netstandard1.0\\xunit.abstractions.dll"));
}