Bump test projects up to .NET 4.5.2

- aspnet/Testing#248
- xUnit no longer supports .NET 4.5.1
- build tests for desktop .NET only on Windows
This commit is contained in:
Doug Bunting 2017-02-16 12:15:34 -08:00
parent fa34afd1c5
commit 40eeba4369
9 changed files with 19 additions and 12 deletions

View File

@ -1,7 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFrameworks>net451;netcoreapp1.1</TargetFrameworks>
<TargetFrameworks>net452;netcoreapp1.1</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
<!-- TODO remove when https://github.com/dotnet/sdk/issues/396 is resolved -->
<RuntimeIdentifier Condition=" '$(TargetFramework)' != 'netcoreapp1.1' ">win7-x64</RuntimeIdentifier>
<OutputType>Exe</OutputType>

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
<!-- TODO remove when https://github.com/dotnet/sdk/issues/396 is resolved -->
<RuntimeIdentifier Condition=" '$(TargetFramework)' != 'netcoreapp1.1' ">win7-x64</RuntimeIdentifier>
<OutputType>Exe</OutputType>

View File

@ -59,7 +59,7 @@ namespace Microsoft.AspNetCore.Localization.FunctionalTests
{
ApplicationBaseUriHint = applicationBaseUrl,
EnvironmentName = environmentName,
TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.1"
TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net452" : "netcoreapp1.1"
};
using (var deployer = ApplicationDeployerFactory.Create(deploymentParameters, logger))

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
</PropertyGroup>
<ItemGroup>

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
</PropertyGroup>
<ItemGroup>

View File

@ -37,7 +37,7 @@ namespace Microsoft.AspNetCore.Localization.Tests
{
// Arrange
var explicitCulture = new CultureInfo("fr-FR");
#if NET451
#if NET452
Thread.CurrentThread.CurrentCulture = explicitCulture;
Thread.CurrentThread.CurrentUICulture = explicitCulture;
#else
@ -78,7 +78,7 @@ namespace Microsoft.AspNetCore.Localization.Tests
{
// Arrange
var explicitCulture = new CultureInfo("fr-FR");
#if NET451
#if NET452
Thread.CurrentThread.CurrentCulture = explicitCulture;
Thread.CurrentThread.CurrentUICulture = explicitCulture;
#else
@ -96,7 +96,7 @@ namespace Microsoft.AspNetCore.Localization.Tests
public void Dispose()
{
#if NET451
#if NET452
Thread.CurrentThread.CurrentCulture = _initialCulture;
Thread.CurrentThread.CurrentUICulture = _initialUICulture;
#else

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
</PropertyGroup>
<ItemGroup>

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>net451;netstandard1.6</TargetFrameworks>
<TargetFrameworks>net452;netstandard1.6</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netstandard1.6</TargetFrameworks>
</PropertyGroup>
</Project>

View File

@ -3,7 +3,8 @@
<Import Project="..\..\build\common.props" />
<PropertyGroup>
<TargetFrameworks>net451;netstandard1.6</TargetFrameworks>
<TargetFrameworks>net452;netstandard1.6</TargetFrameworks>
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netstandard1.6</TargetFrameworks>
</PropertyGroup>
<ItemGroup>