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:
parent
945b4e63de
commit
d4800d188a
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http.Features\Microsoft.AspNetCore.Http.Features.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http.Features\Microsoft.AspNetCore.Http.Features.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@ namespace Microsoft.AspNetCore.Http
|
||||||
contextFactory.Dispose(context);
|
contextFactory.Dispose(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if NET451
|
#if NET452
|
||||||
private static void DomainFunc()
|
private static void DomainFunc()
|
||||||
{
|
{
|
||||||
var accessor = new HttpContextAccessor();
|
var accessor = new HttpContextAccessor();
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.Http\Microsoft.AspNetCore.Http.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -293,7 +293,7 @@ namespace Microsoft.AspNetCore.WebUtilities
|
||||||
|
|
||||||
private static string GetCurrentDirectory()
|
private static string GetCurrentDirectory()
|
||||||
{
|
{
|
||||||
#if NET451
|
#if NET452
|
||||||
return AppDomain.CurrentDomain.BaseDirectory;
|
return AppDomain.CurrentDomain.BaseDirectory;
|
||||||
#else
|
#else
|
||||||
return AppContext.BaseDirectory;
|
return AppContext.BaseDirectory;
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test
|
||||||
Assert.Equal(expectedData, memoryStream.ToArray());
|
Assert.Equal(expectedData, memoryStream.ToArray());
|
||||||
}
|
}
|
||||||
|
|
||||||
#if NET451
|
#if NET452
|
||||||
[Fact]
|
[Fact]
|
||||||
public async Task DoesNotFlush_UnderlyingStream_OnClosingWriter()
|
public async Task DoesNotFlush_UnderlyingStream_OnClosingWriter()
|
||||||
{
|
{
|
||||||
|
|
@ -68,7 +68,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test
|
||||||
Assert.Equal(0, stream.FlushAsyncCallCount);
|
Assert.Equal(0, stream.FlushAsyncCallCount);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if NET451
|
#if NET452
|
||||||
[Fact]
|
[Fact]
|
||||||
public async Task DoesNotClose_UnderlyingStream_OnDisposingWriter()
|
public async Task DoesNotClose_UnderlyingStream_OnDisposingWriter()
|
||||||
{
|
{
|
||||||
|
|
@ -113,7 +113,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test
|
||||||
await writer.WriteAsync(new string('a', byteLength));
|
await writer.WriteAsync(new string('a', byteLength));
|
||||||
|
|
||||||
// Act
|
// Act
|
||||||
#if NET451
|
#if NET452
|
||||||
writer.Close();
|
writer.Close();
|
||||||
#else
|
#else
|
||||||
writer.Dispose();
|
writer.Dispose();
|
||||||
|
|
@ -502,7 +502,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test
|
||||||
return base.WriteAsync(buffer, offset, count, cancellationToken);
|
return base.WriteAsync(buffer, offset, count, cancellationToken);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if NET451
|
#if NET452
|
||||||
public override void Close()
|
public override void Close()
|
||||||
{
|
{
|
||||||
CloseCallCount++;
|
CloseCallCount++;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.WebUtilities\Microsoft.AspNetCore.WebUtilities.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AspNetCore.WebUtilities\Microsoft.AspNetCore.WebUtilities.csproj" />
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,8 @@
|
||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
<Import Project="..\..\build\common.props" />
|
<Import Project="..\..\build\common.props" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFrameworks>netcoreapp1.1;net451</TargetFrameworks>
|
<TargetFrameworks>netcoreapp1.1;net452</TargetFrameworks>
|
||||||
|
<TargetFrameworks Condition=" '$(OS)' != 'Windows_NT' ">netcoreapp1.1</TargetFrameworks>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.Net.Http.Headers\Microsoft.Net.Http.Headers.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.Net.Http.Headers\Microsoft.Net.Http.Headers.csproj" />
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue