Skip to content

Commit e8a5179

Browse files
Fabricio Correa DuarteFabricio Correa Duarte
authored andcommitted
Moved support to specflow 2.1.0
1 parent 64357a9 commit e8a5179

13 files changed

Lines changed: 101 additions & 86 deletions
Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,25 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<package xmlns="http://schemas.microsoft.com/packaging/2011/10/nuspec.xsd">
3-
<metadata>
4-
<id>specflow.plugins.codedui</id>
5-
<version>1.0.0-beta</version>
6-
<authors>Fabricio Correa Duarte</authors>
7-
<owners>Fabricio Correa Duarte</owners>
8-
<licenseUrl>https://raw.github.com/SpecFlow-Plugins/coded-ui/master/LICENSE</licenseUrl>
9-
<iconUrl>https://raw.githubusercontent.com/SpecFlow-Plugins/coded-ui/master/src/logo.png</iconUrl>
10-
<projectUrl>https://github.com/SpecFlow-Plugins/coded-ui</projectUrl>
11-
<requireLicenseAcceptance>false</requireLicenseAcceptance>
12-
<summary>This project enables the execution of Coded-UI operations from within SpecFlow's step definitions.</summary>
13-
<description>Coded UI plug-in for SpecFlow</description>
14-
<language>en-US</language>
15-
<dependencies>
16-
<dependency id="SpecFlow" version="[1.9.0]" />
17-
</dependencies>
18-
</metadata>
19-
<files>
20-
<file src="src\SpecFlow.Plugins.CodedUi\bin\CodedUi.Generator.SpecFlowPlugin.dll" target="content" />
21-
<file src="pipe\App.config.install.xdt" target="content" />
22-
<file src="pipe\App.config.uninstall.xdt" target="content" />
23-
</files>
3+
<metadata>
4+
<id>specflow.plugins.codedui</id>
5+
<version>1.0.0-beta</version>
6+
<authors>Fabricio Correa Duarte</authors>
7+
<owners>Fabricio Correa Duarte</owners>
8+
<licenseUrl>https://raw.github.com/SpecFlow-Plugins/coded-ui/master/LICENSE</licenseUrl>
9+
<iconUrl>https://raw.githubusercontent.com/SpecFlow-Plugins/coded-ui/master/src/logo.png</iconUrl>
10+
<projectUrl>https://github.com/SpecFlow-Plugins/coded-ui</projectUrl>
11+
<requireLicenseAcceptance>false</requireLicenseAcceptance>
12+
<summary>This project enables the execution of Coded-UI operations from within SpecFlow's step definitions.</summary>
13+
<description>Coded UI plug-in for SpecFlow</description>
14+
<language>en-US</language>
15+
<releaseNotes>Moved support to specflow 2.1.0 incurring lowest .net framework 4.5</releaseNotes>
16+
<dependencies>
17+
<dependency id="SpecFlow" version="[2.1.0]" />
18+
</dependencies>
19+
</metadata>
20+
<files>
21+
<file src="src\SpecFlow.Plugins.CodedUi\bin\CodedUi.Generator.SpecFlowPlugin.dll" target="content" />
22+
<file src="pipe\App.config.install.xdt" target="content" />
23+
<file src="pipe\App.config.uninstall.xdt" target="content" />
24+
</files>
2425
</package>

src/Calculator.Specs/App.config

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,14 @@
33
<configSections>
44
<section name="specFlow" type="TechTalk.SpecFlow.Configuration.ConfigurationSectionHandler, TechTalk.SpecFlow" />
55
</configSections>
6-
7-
8-
9-
106
<specFlow>
11-
<!-- For additional details on SpecFlow configuration options see http://go.specflow.org/doc-config -->
127
<unitTestProvider name="MsTest" />
13-
148
<plugins>
159
<add name="CodedUi" path="..\lib" type="Generator" />
1610
</plugins>
17-
11+
<!-- For additional details on SpecFlow configuration options see http://go.specflow.org/doc-config -->
1812
</specFlow>
13+
<startup>
14+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
15+
</startup>
1916
</configuration>

src/Calculator.Specs/Calculator.Specs.csproj

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<AppDesignerFolder>Properties</AppDesignerFolder>
1212
<RootNamespace>Calculator.Specs</RootNamespace>
1313
<AssemblyName>Calculator.Specs</AssemblyName>
14-
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
14+
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
1515
<FileAlignment>512</FileAlignment>
1616
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
1717
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
@@ -31,6 +31,7 @@
3131
<DefineConstants>DEBUG;TRACE</DefineConstants>
3232
<ErrorReport>prompt</ErrorReport>
3333
<WarningLevel>4</WarningLevel>
34+
<Prefer32Bit>false</Prefer32Bit>
3435
</PropertyGroup>
3536
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
3637
<DebugType>pdbonly</DebugType>
@@ -39,6 +40,7 @@
3940
<DefineConstants>TRACE</DefineConstants>
4041
<ErrorReport>prompt</ErrorReport>
4142
<WarningLevel>4</WarningLevel>
43+
<Prefer32Bit>false</Prefer32Bit>
4244
</PropertyGroup>
4345
<ItemGroup>
4446
<Reference Include="Microsoft.VisualStudio.QualityTools.CodedUITestFramework">
@@ -57,8 +59,9 @@
5759
<Reference Include="System.Data" />
5860
<Reference Include="System.Drawing" />
5961
<Reference Include="System.Windows.Forms" />
60-
<Reference Include="TechTalk.SpecFlow">
61-
<HintPath>..\packages\SpecFlow.1.9.0\lib\net35\TechTalk.SpecFlow.dll</HintPath>
62+
<Reference Include="TechTalk.SpecFlow, Version=2.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
63+
<HintPath>..\packages\SpecFlow.2.1.0\lib\net45\TechTalk.SpecFlow.dll</HintPath>
64+
<Private>True</Private>
6265
</Reference>
6366
<Reference Include="WindowsBase" />
6467
</ItemGroup>

src/Calculator.Specs/Features/Addition.feature.cs

Lines changed: 16 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="SpecFlow" version="1.9.0" targetFramework="net40" />
3+
<package id="SpecFlow" version="2.1.0" targetFramework="net45" />
44
</packages>

src/SpecFlow.Plugins.CodedUi/App.config

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
<?xml version="1.0" encoding="utf-8"?>
1+
<?xml version="1.0" encoding="utf-8"?>
22
<configuration>
33
<configSections>
4-
<section name="specFlow" type="TechTalk.SpecFlow.Configuration.ConfigurationSectionHandler, TechTalk.SpecFlow"/>
4+
<section name="specFlow" type="TechTalk.SpecFlow.Configuration.ConfigurationSectionHandler, TechTalk.SpecFlow" />
55
</configSections>
66

7+
78
<startup>
89

9-
<supportedRuntime version="v2.0.50727"/></startup>
10+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" /></startup>
1011

1112
<specFlow>
1213
<!-- For additional details on SpecFlow configuration options see http://go.specflow.org/doc-config -->

src/SpecFlow.Plugins.CodedUi/CodedUiPlugin.cs

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,15 @@ namespace CodedUi.Generator.SpecFlowPlugin
3030

3131
public class CodedUiPlugin : IGeneratorPlugin
3232
{
33-
#region IGeneratorPlugin Members
34-
35-
public void RegisterConfigurationDefaults(TechTalk.SpecFlow.Generator.Configuration.SpecFlowProjectConfiguration specFlowConfiguration) { }
36-
37-
public void RegisterCustomizations(BoDi.ObjectContainer container, TechTalk.SpecFlow.Generator.Configuration.SpecFlowProjectConfiguration generatorConfiguration)
33+
public void Initialize(GeneratorPluginEvents generatorPluginEvents, GeneratorPluginParameters generatorPluginParameters)
3834
{
39-
container.RegisterTypeAs<CodedUIGeneratorProvider, IUnitTestGeneratorProvider>();
40-
container.RegisterTypeAs<MsTest2010RuntimeProvider, IUnitTestRuntimeProvider>();
35+
generatorPluginEvents.CustomizeDependencies += GeneratorPluginEvents_CustomizeDependencies;
4136
}
4237

43-
public void RegisterDependencies(BoDi.ObjectContainer container) { }
44-
45-
#endregion
38+
private void GeneratorPluginEvents_CustomizeDependencies(object sender, CustomizeDependenciesEventArgs e)
39+
{
40+
e.ObjectContainer.RegisterTypeAs<CodedUIGeneratorProvider, IUnitTestGeneratorProvider>();
41+
e.ObjectContainer.RegisterTypeAs<MsTest2010RuntimeProvider, IUnitTestRuntimeProvider>();
42+
}
4643
}
4744
}

src/SpecFlow.Plugins.CodedUi/Plugin.csproj

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<AppDesignerFolder>Properties</AppDesignerFolder>
1010
<RootNamespace>CodedUi.Generator.SpecFlowPlugin</RootNamespace>
1111
<AssemblyName>CodedUi.Generator.SpecFlowPlugin</AssemblyName>
12-
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
12+
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
1313
<FileAlignment>512</FileAlignment>
1414
<SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\</SolutionDir>
1515
<RestorePackages>true</RestorePackages>
@@ -35,27 +35,31 @@
3535
<Prefer32Bit>false</Prefer32Bit>
3636
</PropertyGroup>
3737
<ItemGroup>
38+
<Reference Include="Gherkin, Version=1.0.0.0, Culture=neutral, PublicKeyToken=86496cfa5b4a5851, processorArchitecture=MSIL">
39+
<HintPath>..\packages\SpecFlow.CustomPlugin.2.1.0\lib\net45\Gherkin.dll</HintPath>
40+
<Private>True</Private>
41+
</Reference>
3842
<Reference Include="System" />
3943
<Reference Include="System.Core" />
4044
<Reference Include="System.Xml.Linq" />
4145
<Reference Include="System.Data.DataSetExtensions" />
4246
<Reference Include="System.Data" />
4347
<Reference Include="System.Xml" />
44-
<Reference Include="TechTalk.SpecFlow, Version=1.9.0.77, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
45-
<SpecificVersion>False</SpecificVersion>
46-
<HintPath>..\packages\SpecFlow.1.9.0\lib\net35\TechTalk.SpecFlow.dll</HintPath>
48+
<Reference Include="TechTalk.SpecFlow, Version=2.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
49+
<HintPath>..\packages\SpecFlow.2.1.0\lib\net45\TechTalk.SpecFlow.dll</HintPath>
50+
<Private>True</Private>
4751
</Reference>
48-
<Reference Include="TechTalk.SpecFlow.Generator, Version=1.9.0.77, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
49-
<SpecificVersion>False</SpecificVersion>
50-
<HintPath>..\packages\SpecFlow.CustomPlugin.1.9.0\lib\net40\TechTalk.SpecFlow.Generator.dll</HintPath>
52+
<Reference Include="TechTalk.SpecFlow.Generator, Version=2.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
53+
<HintPath>..\packages\SpecFlow.CustomPlugin.2.1.0\lib\net45\TechTalk.SpecFlow.Generator.dll</HintPath>
54+
<Private>True</Private>
5155
</Reference>
52-
<Reference Include="TechTalk.SpecFlow.Parser, Version=1.9.0.77, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
53-
<SpecificVersion>False</SpecificVersion>
54-
<HintPath>..\packages\SpecFlow.CustomPlugin.1.9.0\lib\net40\TechTalk.SpecFlow.Parser.dll</HintPath>
56+
<Reference Include="TechTalk.SpecFlow.Parser, Version=2.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
57+
<HintPath>..\packages\SpecFlow.CustomPlugin.2.1.0\lib\net45\TechTalk.SpecFlow.Parser.dll</HintPath>
58+
<Private>True</Private>
5559
</Reference>
56-
<Reference Include="TechTalk.SpecFlow.Utils, Version=1.9.0.77, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
57-
<SpecificVersion>False</SpecificVersion>
58-
<HintPath>..\packages\SpecFlow.CustomPlugin.1.9.0\lib\net40\TechTalk.SpecFlow.Utils.dll</HintPath>
60+
<Reference Include="TechTalk.SpecFlow.Utils, Version=2.1.0.0, Culture=neutral, PublicKeyToken=0778194805d6db41, processorArchitecture=MSIL">
61+
<HintPath>..\packages\SpecFlow.CustomPlugin.2.1.0\lib\net45\TechTalk.SpecFlow.Utils.dll</HintPath>
62+
<Private>True</Private>
5963
</Reference>
6064
</ItemGroup>
6165
<ItemGroup>
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="SpecFlow" version="1.9.0" targetFramework="net40" />
4-
<package id="SpecFlow.CustomPlugin" version="1.9.0" targetFramework="net40" requireReinstallation="True" />
3+
<package id="SpecFlow" version="2.1.0" targetFramework="net45" />
4+
<package id="SpecFlow.CustomPlugin" version="2.1.0" targetFramework="net45" />
55
</packages>

src/UnitTests/App.config

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
<configSections>
44
<section name="specFlow" type="TechTalk.SpecFlow.Configuration.ConfigurationSectionHandler, TechTalk.SpecFlow" />
55
</configSections>
6-
<specFlow>
6+
7+
8+
<specFlow>
79
<!-- For additional details on SpecFlow configuration options see http://go.specflow.org/doc-config -->
8-
</specFlow>
9-
</configuration>
10+
</specFlow></configuration>

0 commit comments

Comments
 (0)