Converted test project to run on netcoreapp2.0

This commit is contained in:
Kiran Challa 2017-03-21 16:57:47 -07:00 committed by Kiran Challa
parent 151e792ecb
commit f31c302e5c
3 changed files with 6 additions and 2 deletions

View File

@ -4,6 +4,7 @@
<CoreFxVersion>4.3.0</CoreFxVersion>
<MoqVersion>4.7.1</MoqVersion>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<RuntimeFrameworkVersion>2.0.0-*</RuntimeFrameworkVersion>
<TestSdkVersion>15.0.0</TestSdkVersion>
<XunitVersion>2.2.0</XunitVersion>
</PropertyGroup>

View File

@ -63,6 +63,9 @@ namespace Microsoft.AspNetCore.Antiforgery.Internal
#if NET452
// CoreCLR doesn't support an 'empty' name
identity.AddClaim(new Claim(ClaimTypes.NameIdentifier, string.Empty));
#elif NETCOREAPP2_0
#else
#error Target framework needs to be updated
#endif
// Arrange

View File

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