Skip to content
This repository was archived by the owner on Nov 7, 2019. It is now read-only.

Commit 3cf44d4

Browse files
committed
SpecFlow v2 is compiled for .NET 4.5 so no longer need to set the startup runtime.
1 parent 7584e71 commit 3cf44d4

File tree

3 files changed

+3
-22
lines changed

3 files changed

+3
-22
lines changed

samples/VS2015/SpecFlow 2.1.0/net461/Sample.Website.Tests/project.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111
"Sample.Website": "1.0.0-*",
1212
"SpecFlow": "2.1.0",
1313
"xunit": "2.2.0-beta2-build3300",
14-
"dotnet-test-xunit": "2.2.0-*"
14+
"dotnet-test-xunit": "2.2.0-preview2-build1029"
1515
},
1616

1717
"tools": {
18-
"SpecFlow.NetCore": "1.0.0-*"
18+
"SpecFlow.NetCore": "1.0.0-rc4"
1919
},
2020

2121
"testRunner": "xunit",

src/SpecFlow.NetCore/Fixer.cs

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -72,23 +72,6 @@ private void FixXunit(DirectoryInfo directory)
7272
}
7373
}
7474

75-
private string SaveSpecFlowConfig()
76-
{
77-
// Target later version of .NET.
78-
// Credit: http://stackoverflow.com/questions/11363202/specflow-fails-when-trying-to-generate-test-execution-report
79-
80-
WriteLine("Generating specflow.exe.config.");
81-
82-
var configPath = _specFlowExe + ".config";
83-
var content = "<?xml version=\"1.0\" encoding=\"utf-8\" ?><configuration><startup><supportedRuntime version=\"v4.0.30319\" /></startup></configuration>";
84-
WriteLine(content);
85-
86-
WriteLine("Saving: " + configPath);
87-
File.WriteAllText(configPath, content);
88-
89-
return configPath;
90-
}
91-
9275
private void RunSpecFlow(string csproj)
9376
{
9477
// Credit: http://www.marcusoft.net/2010/12/specflowexe-and-mstest.html
@@ -126,9 +109,7 @@ private void DeleteSpecFlowConfig(string configPath)
126109
private void GenerateSpecFlowGlue(DirectoryInfo directory, FileInfo fakeCsproj)
127110
{
128111
AppConfig.CreateIn(directory).Validate();
129-
var specFlowConfigPath = SaveSpecFlowConfig();
130112
RunSpecFlow(fakeCsproj.Name);
131-
DeleteSpecFlowConfig(specFlowConfigPath);
132113
}
133114

134115
private FileInfo SaveFakeCsProj(DirectoryInfo directory, FileInfo xproj)

src/SpecFlow.NetCore/project.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.0.0-rc3",
2+
"version": "1.0.0-rc4",
33
"description": "Generate tests from SpecFlow feature files inside ASP.NET Core projects (.xproj's).",
44
"authors": [ "stajs" ],
55

0 commit comments

Comments
 (0)