diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssembly.sln b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly.sln new file mode 100644 index 0000000..2ee53a7 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly.sln @@ -0,0 +1,31 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.28721.148 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AdditionalStepAssembly", "AdditionalStepAssembly\AdditionalStepAssembly.csproj", "{45E2FC12-FA9F-435A-9685-5C14791C81D6}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AdditionalStepAssemblyFullFramework", "AdditionalStepAssemblyFullFramework\AdditionalStepAssemblyFullFramework.csproj", "{5E3F51A0-5754-4272-8CDF-CB01625451C4}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {45E2FC12-FA9F-435A-9685-5C14791C81D6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {45E2FC12-FA9F-435A-9685-5C14791C81D6}.Debug|Any CPU.Build.0 = Debug|Any CPU + {45E2FC12-FA9F-435A-9685-5C14791C81D6}.Release|Any CPU.ActiveCfg = Release|Any CPU + {45E2FC12-FA9F-435A-9685-5C14791C81D6}.Release|Any CPU.Build.0 = Release|Any CPU + {5E3F51A0-5754-4272-8CDF-CB01625451C4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {5E3F51A0-5754-4272-8CDF-CB01625451C4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {5E3F51A0-5754-4272-8CDF-CB01625451C4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {5E3F51A0-5754-4272-8CDF-CB01625451C4}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2B1E1CBE-0BF3-4307-A5C4-CF69F6B88A8E} + EndGlobalSection +EndGlobal diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/AdditionalStepAssembly.csproj b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/AdditionalStepAssembly.csproj new file mode 100644 index 0000000..c2b1271 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/AdditionalStepAssembly.csproj @@ -0,0 +1,24 @@ + + + + netcoreapp3.1 + + false + + + + + + + + + + + + + Always + + + + + diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature new file mode 100644 index 0000000..d6ff076 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature @@ -0,0 +1,11 @@ +Feature: SpecFlowFeature1 + In order to avoid silly mistakes + As a math idiot + I want to be told the sum of two numbers + +@mytag +Scenario: Add two numbers + Given I have entered 50 into the calculator + And I have entered 70 into the calculator + When I press add + Then the result should be 120 on the screen diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature.cs b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature.cs new file mode 100644 index 0000000..c7ce15a --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/SpecFlowFeature1.feature.cs @@ -0,0 +1,138 @@ +// ------------------------------------------------------------------------------ +// +// This code was generated by SpecFlow (https://www.specflow.org/). +// SpecFlow Version:3.9.0.0 +// SpecFlow Generator Version:3.9.0.0 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +// ------------------------------------------------------------------------------ +#region Designer generated code +#pragma warning disable +namespace AdditionalStepAssembly +{ + using TechTalk.SpecFlow; + using System; + using System.Linq; + + + [System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.9.0.0")] + [System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + public partial class SpecFlowFeature1Feature : object, Xunit.IClassFixture, System.IDisposable + { + + private static TechTalk.SpecFlow.ITestRunner testRunner; + + private static string[] featureTags = ((string[])(null)); + + private Xunit.Abstractions.ITestOutputHelper _testOutputHelper; + +#line 1 "SpecFlowFeature1.feature" +#line hidden + + public SpecFlowFeature1Feature(SpecFlowFeature1Feature.FixtureData fixtureData, AdditionalStepAssembly_XUnitAssemblyFixture assemblyFixture, Xunit.Abstractions.ITestOutputHelper testOutputHelper) + { + this._testOutputHelper = testOutputHelper; + this.TestInitialize(); + } + + public static void FeatureSetup() + { + testRunner = TechTalk.SpecFlow.TestRunnerManager.GetTestRunner(); + TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "", "SpecFlowFeature1", "\tIn order to avoid silly mistakes\n\tAs a math idiot\n\tI want to be told the sum of " + + "two numbers", ProgrammingLanguage.CSharp, featureTags); + testRunner.OnFeatureStart(featureInfo); + } + + public static void FeatureTearDown() + { + testRunner.OnFeatureEnd(); + testRunner = null; + } + + public void TestInitialize() + { + } + + public void TestTearDown() + { + testRunner.OnScenarioEnd(); + } + + public void ScenarioInitialize(TechTalk.SpecFlow.ScenarioInfo scenarioInfo) + { + testRunner.OnScenarioInitialize(scenarioInfo); + testRunner.ScenarioContext.ScenarioContainer.RegisterInstanceAs(_testOutputHelper); + } + + public void ScenarioStart() + { + testRunner.OnScenarioStart(); + } + + public void ScenarioCleanup() + { + testRunner.CollectScenarioErrors(); + } + + void System.IDisposable.Dispose() + { + this.TestTearDown(); + } + + [Xunit.SkippableFactAttribute(DisplayName="Add two numbers")] + [Xunit.TraitAttribute("FeatureTitle", "SpecFlowFeature1")] + [Xunit.TraitAttribute("Description", "Add two numbers")] + [Xunit.TraitAttribute("Category", "mytag")] + public void AddTwoNumbers() + { + string[] tagsOfScenario = new string[] { + "mytag"}; + System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary(); + TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add two numbers", null, tagsOfScenario, argumentsOfScenario, featureTags); +#line 7 +this.ScenarioInitialize(scenarioInfo); +#line hidden + if ((TagHelper.ContainsIgnoreTag(tagsOfScenario) || TagHelper.ContainsIgnoreTag(featureTags))) + { + testRunner.SkipScenario(); + } + else + { + this.ScenarioStart(); +#line 8 + testRunner.Given("I have entered 50 into the calculator", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given "); +#line hidden +#line 9 + testRunner.And("I have entered 70 into the calculator", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And "); +#line hidden +#line 10 + testRunner.When("I press add", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When "); +#line hidden +#line 11 + testRunner.Then("the result should be 120 on the screen", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then "); +#line hidden + } + this.ScenarioCleanup(); + } + + [System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.9.0.0")] + [System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + public class FixtureData : System.IDisposable + { + + public FixtureData() + { + SpecFlowFeature1Feature.FeatureSetup(); + } + + void System.IDisposable.Dispose() + { + SpecFlowFeature1Feature.FeatureTearDown(); + } + } + } +} +#pragma warning restore +#endregion diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/specflow.json b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/specflow.json new file mode 100644 index 0000000..1d2120d --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssembly/specflow.json @@ -0,0 +1,12 @@ +{ + "bindingCulture": { + "language": "en-us" + }, + "language": { + "feature": "en-us" + }, + "plugins": [], + "stepAssemblies": [ + { "assembly": "SecondStepAssembly" } + ] +} diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/AdditionalStepAssemblyFullFramework.csproj b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/AdditionalStepAssemblyFullFramework.csproj new file mode 100644 index 0000000..92234b1 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/AdditionalStepAssemblyFullFramework.csproj @@ -0,0 +1,17 @@ + + + + net471 + + false + + + + + + + + + + + diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature new file mode 100644 index 0000000..d6ff076 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature @@ -0,0 +1,11 @@ +Feature: SpecFlowFeature1 + In order to avoid silly mistakes + As a math idiot + I want to be told the sum of two numbers + +@mytag +Scenario: Add two numbers + Given I have entered 50 into the calculator + And I have entered 70 into the calculator + When I press add + Then the result should be 120 on the screen diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature.cs b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature.cs new file mode 100644 index 0000000..a0ae57b --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/SpecFlowFeature1.feature.cs @@ -0,0 +1,138 @@ +// ------------------------------------------------------------------------------ +// +// This code was generated by SpecFlow (https://www.specflow.org/). +// SpecFlow Version:3.9.0.0 +// SpecFlow Generator Version:3.9.0.0 +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +// ------------------------------------------------------------------------------ +#region Designer generated code +#pragma warning disable +namespace AdditionalStepAssemblyFullFramework +{ + using TechTalk.SpecFlow; + using System; + using System.Linq; + + + [System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.9.0.0")] + [System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + public partial class SpecFlowFeature1Feature : object, Xunit.IClassFixture, System.IDisposable + { + + private static TechTalk.SpecFlow.ITestRunner testRunner; + + private static string[] featureTags = ((string[])(null)); + + private Xunit.Abstractions.ITestOutputHelper _testOutputHelper; + +#line 1 "SpecFlowFeature1.feature" +#line hidden + + public SpecFlowFeature1Feature(SpecFlowFeature1Feature.FixtureData fixtureData, AdditionalStepAssemblyFullFramework_XUnitAssemblyFixture assemblyFixture, Xunit.Abstractions.ITestOutputHelper testOutputHelper) + { + this._testOutputHelper = testOutputHelper; + this.TestInitialize(); + } + + public static void FeatureSetup() + { + testRunner = TechTalk.SpecFlow.TestRunnerManager.GetTestRunner(); + TechTalk.SpecFlow.FeatureInfo featureInfo = new TechTalk.SpecFlow.FeatureInfo(new System.Globalization.CultureInfo("en-US"), "", "SpecFlowFeature1", "\tIn order to avoid silly mistakes\n\tAs a math idiot\n\tI want to be told the sum of " + + "two numbers", ProgrammingLanguage.CSharp, featureTags); + testRunner.OnFeatureStart(featureInfo); + } + + public static void FeatureTearDown() + { + testRunner.OnFeatureEnd(); + testRunner = null; + } + + public void TestInitialize() + { + } + + public void TestTearDown() + { + testRunner.OnScenarioEnd(); + } + + public void ScenarioInitialize(TechTalk.SpecFlow.ScenarioInfo scenarioInfo) + { + testRunner.OnScenarioInitialize(scenarioInfo); + testRunner.ScenarioContext.ScenarioContainer.RegisterInstanceAs(_testOutputHelper); + } + + public void ScenarioStart() + { + testRunner.OnScenarioStart(); + } + + public void ScenarioCleanup() + { + testRunner.CollectScenarioErrors(); + } + + void System.IDisposable.Dispose() + { + this.TestTearDown(); + } + + [Xunit.SkippableFactAttribute(DisplayName="Add two numbers")] + [Xunit.TraitAttribute("FeatureTitle", "SpecFlowFeature1")] + [Xunit.TraitAttribute("Description", "Add two numbers")] + [Xunit.TraitAttribute("Category", "mytag")] + public void AddTwoNumbers() + { + string[] tagsOfScenario = new string[] { + "mytag"}; + System.Collections.Specialized.OrderedDictionary argumentsOfScenario = new System.Collections.Specialized.OrderedDictionary(); + TechTalk.SpecFlow.ScenarioInfo scenarioInfo = new TechTalk.SpecFlow.ScenarioInfo("Add two numbers", null, tagsOfScenario, argumentsOfScenario, featureTags); +#line 7 +this.ScenarioInitialize(scenarioInfo); +#line hidden + if ((TagHelper.ContainsIgnoreTag(tagsOfScenario) || TagHelper.ContainsIgnoreTag(featureTags))) + { + testRunner.SkipScenario(); + } + else + { + this.ScenarioStart(); +#line 8 + testRunner.Given("I have entered 50 into the calculator", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Given "); +#line hidden +#line 9 + testRunner.And("I have entered 70 into the calculator", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "And "); +#line hidden +#line 10 + testRunner.When("I press add", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "When "); +#line hidden +#line 11 + testRunner.Then("the result should be 120 on the screen", ((string)(null)), ((TechTalk.SpecFlow.Table)(null)), "Then "); +#line hidden + } + this.ScenarioCleanup(); + } + + [System.CodeDom.Compiler.GeneratedCodeAttribute("TechTalk.SpecFlow", "3.9.0.0")] + [System.Runtime.CompilerServices.CompilerGeneratedAttribute()] + public class FixtureData : System.IDisposable + { + + public FixtureData() + { + SpecFlowFeature1Feature.FeatureSetup(); + } + + void System.IDisposable.Dispose() + { + SpecFlowFeature1Feature.FeatureTearDown(); + } + } + } +} +#pragma warning restore +#endregion diff --git a/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/app.config b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/app.config new file mode 100644 index 0000000..7c92987 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/AdditionalStepAssemblyFullFramework/app.config @@ -0,0 +1,13 @@ + + + +
+ + + + + + + + + \ No newline at end of file diff --git a/testProjects/AdditionalStepAssembly/SecondStepAssembly/Bindings.cs b/testProjects/AdditionalStepAssembly/SecondStepAssembly/Bindings.cs new file mode 100644 index 0000000..7332559 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/SecondStepAssembly/Bindings.cs @@ -0,0 +1,25 @@ +using System; +using TechTalk.SpecFlow; + +namespace SecondStepAssembly +{ + [Binding] + public class Bindings + { + [Given(@"I have entered (.*) into the calculator")] + public void GivenIHaveEnteredIntoTheCalculator(int p0) + { + } + + [When(@"I press add")] + public void WhenIPressAdd() + { + } + + [Then(@"the result should be (.*) on the screen")] + public void ThenTheResultShouldBeOnTheScreen(int p0) + { + } + + } +} diff --git a/testProjects/AdditionalStepAssembly/SecondStepAssembly/SecondStepAssembly.csproj b/testProjects/AdditionalStepAssembly/SecondStepAssembly/SecondStepAssembly.csproj new file mode 100644 index 0000000..c8668aa --- /dev/null +++ b/testProjects/AdditionalStepAssembly/SecondStepAssembly/SecondStepAssembly.csproj @@ -0,0 +1,11 @@ + + + + netstandard2.0 + + + + + + + diff --git a/testProjects/AdditionalStepAssembly/nuget.config b/testProjects/AdditionalStepAssembly/nuget.config new file mode 100644 index 0000000..784e3e4 --- /dev/null +++ b/testProjects/AdditionalStepAssembly/nuget.config @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/testProjects/AdditionalStepAssembly/nuget/SecondStepAssembly.1.0.0.nupkg b/testProjects/AdditionalStepAssembly/nuget/SecondStepAssembly.1.0.0.nupkg new file mode 100644 index 0000000..0bbe9c7 Binary files /dev/null and b/testProjects/AdditionalStepAssembly/nuget/SecondStepAssembly.1.0.0.nupkg differ