From d4800d188ad261258bb3bf83a112c23fcda71f54 Mon Sep 17 00:00:00 2001 From: Doug Bunting Date: Tue, 14 Feb 2017 08:37:12 -0800 Subject: [PATCH] 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 --- .../Microsoft.AspNetCore.Http.Abstractions.Tests.csproj | 3 ++- .../Microsoft.AspNetCore.Http.Extensions.Tests.csproj | 3 ++- .../Microsoft.AspNetCore.Http.Features.Tests.csproj | 3 ++- .../HttpContextFactoryTests.cs | 2 +- .../Microsoft.AspNetCore.Http.Tests.csproj | 3 ++- .../Microsoft.AspNetCore.Owin.Tests.csproj | 3 ++- .../FileBufferingReadStreamTests.cs | 2 +- .../HttpResponseStreamWriterTest.cs | 8 ++++---- .../Microsoft.AspNetCore.WebUtilities.Tests.csproj | 3 ++- .../Microsoft.Net.Http.Headers.Tests.csproj | 3 ++- 10 files changed, 20 insertions(+), 13 deletions(-) diff --git a/test/Microsoft.AspNetCore.Http.Abstractions.Tests/Microsoft.AspNetCore.Http.Abstractions.Tests.csproj b/test/Microsoft.AspNetCore.Http.Abstractions.Tests/Microsoft.AspNetCore.Http.Abstractions.Tests.csproj index fcef246218..bfa23bee84 100644 --- a/test/Microsoft.AspNetCore.Http.Abstractions.Tests/Microsoft.AspNetCore.Http.Abstractions.Tests.csproj +++ b/test/Microsoft.AspNetCore.Http.Abstractions.Tests/Microsoft.AspNetCore.Http.Abstractions.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.AspNetCore.Http.Extensions.Tests/Microsoft.AspNetCore.Http.Extensions.Tests.csproj b/test/Microsoft.AspNetCore.Http.Extensions.Tests/Microsoft.AspNetCore.Http.Extensions.Tests.csproj index 81f3d395b8..5c45065ffc 100644 --- a/test/Microsoft.AspNetCore.Http.Extensions.Tests/Microsoft.AspNetCore.Http.Extensions.Tests.csproj +++ b/test/Microsoft.AspNetCore.Http.Extensions.Tests/Microsoft.AspNetCore.Http.Extensions.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.AspNetCore.Http.Features.Tests/Microsoft.AspNetCore.Http.Features.Tests.csproj b/test/Microsoft.AspNetCore.Http.Features.Tests/Microsoft.AspNetCore.Http.Features.Tests.csproj index 014ee7ea8f..c516e5c729 100644 --- a/test/Microsoft.AspNetCore.Http.Features.Tests/Microsoft.AspNetCore.Http.Features.Tests.csproj +++ b/test/Microsoft.AspNetCore.Http.Features.Tests/Microsoft.AspNetCore.Http.Features.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.AspNetCore.Http.Tests/HttpContextFactoryTests.cs b/test/Microsoft.AspNetCore.Http.Tests/HttpContextFactoryTests.cs index 0fa3247dae..fc5c5386fa 100644 --- a/test/Microsoft.AspNetCore.Http.Tests/HttpContextFactoryTests.cs +++ b/test/Microsoft.AspNetCore.Http.Tests/HttpContextFactoryTests.cs @@ -36,7 +36,7 @@ namespace Microsoft.AspNetCore.Http contextFactory.Dispose(context); } -#if NET451 +#if NET452 private static void DomainFunc() { var accessor = new HttpContextAccessor(); diff --git a/test/Microsoft.AspNetCore.Http.Tests/Microsoft.AspNetCore.Http.Tests.csproj b/test/Microsoft.AspNetCore.Http.Tests/Microsoft.AspNetCore.Http.Tests.csproj index 12697fb894..174d688198 100644 --- a/test/Microsoft.AspNetCore.Http.Tests/Microsoft.AspNetCore.Http.Tests.csproj +++ b/test/Microsoft.AspNetCore.Http.Tests/Microsoft.AspNetCore.Http.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.AspNetCore.Owin.Tests/Microsoft.AspNetCore.Owin.Tests.csproj b/test/Microsoft.AspNetCore.Owin.Tests/Microsoft.AspNetCore.Owin.Tests.csproj index 1c673f5f04..06b291e3bd 100644 --- a/test/Microsoft.AspNetCore.Owin.Tests/Microsoft.AspNetCore.Owin.Tests.csproj +++ b/test/Microsoft.AspNetCore.Owin.Tests/Microsoft.AspNetCore.Owin.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.AspNetCore.WebUtilities.Tests/FileBufferingReadStreamTests.cs b/test/Microsoft.AspNetCore.WebUtilities.Tests/FileBufferingReadStreamTests.cs index cdb368e6e3..2a96d197da 100644 --- a/test/Microsoft.AspNetCore.WebUtilities.Tests/FileBufferingReadStreamTests.cs +++ b/test/Microsoft.AspNetCore.WebUtilities.Tests/FileBufferingReadStreamTests.cs @@ -293,7 +293,7 @@ namespace Microsoft.AspNetCore.WebUtilities private static string GetCurrentDirectory() { -#if NET451 +#if NET452 return AppDomain.CurrentDomain.BaseDirectory; #else return AppContext.BaseDirectory; diff --git a/test/Microsoft.AspNetCore.WebUtilities.Tests/HttpResponseStreamWriterTest.cs b/test/Microsoft.AspNetCore.WebUtilities.Tests/HttpResponseStreamWriterTest.cs index 7f4c54b5a3..7b68cfbe23 100644 --- a/test/Microsoft.AspNetCore.WebUtilities.Tests/HttpResponseStreamWriterTest.cs +++ b/test/Microsoft.AspNetCore.WebUtilities.Tests/HttpResponseStreamWriterTest.cs @@ -34,7 +34,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test Assert.Equal(expectedData, memoryStream.ToArray()); } -#if NET451 +#if NET452 [Fact] public async Task DoesNotFlush_UnderlyingStream_OnClosingWriter() { @@ -68,7 +68,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test Assert.Equal(0, stream.FlushAsyncCallCount); } -#if NET451 +#if NET452 [Fact] public async Task DoesNotClose_UnderlyingStream_OnDisposingWriter() { @@ -113,7 +113,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test await writer.WriteAsync(new string('a', byteLength)); // Act -#if NET451 +#if NET452 writer.Close(); #else writer.Dispose(); @@ -502,7 +502,7 @@ namespace Microsoft.AspNetCore.WebUtilities.Test return base.WriteAsync(buffer, offset, count, cancellationToken); } -#if NET451 +#if NET452 public override void Close() { CloseCallCount++; diff --git a/test/Microsoft.AspNetCore.WebUtilities.Tests/Microsoft.AspNetCore.WebUtilities.Tests.csproj b/test/Microsoft.AspNetCore.WebUtilities.Tests/Microsoft.AspNetCore.WebUtilities.Tests.csproj index ed91a7b52f..11a622c9c2 100644 --- a/test/Microsoft.AspNetCore.WebUtilities.Tests/Microsoft.AspNetCore.WebUtilities.Tests.csproj +++ b/test/Microsoft.AspNetCore.WebUtilities.Tests/Microsoft.AspNetCore.WebUtilities.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1 diff --git a/test/Microsoft.Net.Http.Headers.Tests/Microsoft.Net.Http.Headers.Tests.csproj b/test/Microsoft.Net.Http.Headers.Tests/Microsoft.Net.Http.Headers.Tests.csproj index 8c7f068a04..1cc3fb5cad 100644 --- a/test/Microsoft.Net.Http.Headers.Tests/Microsoft.Net.Http.Headers.Tests.csproj +++ b/test/Microsoft.Net.Http.Headers.Tests/Microsoft.Net.Http.Headers.Tests.csproj @@ -1,7 +1,8 @@  - netcoreapp1.1;net451 + netcoreapp1.1;net452 + netcoreapp1.1