From a7fc16162ec2c27a455657e5523857377f7f8944 Mon Sep 17 00:00:00 2001 From: Aaron Stannard Date: Mon, 16 Aug 2021 13:50:49 -0500 Subject: [PATCH] standardize Hyperion runtimes through `common.props` (#253) * standardize Hyperion runtimes through common.props * fixed .NET Framework tests * fixed IFDEFs * disable AppDomains in XUnit on Linux * fixed paths * fixed path resolution to `xunit.runner.json` * remove API tests on Linux * fixed net461 ref --- build.fsx | 7 +++--- .../Hyperion.API.Tests.csproj | 3 ++- .../Hyperion.Akka.Integration.Tests.csproj | 3 ++- .../Hyperion.Benchmarks.csproj | 4 ++-- src/Hyperion.Tests/Hyperion.Tests.csproj | 19 ++++++++------- src/common.props | 23 +++++++++++-------- src/xunit.runner.json | 6 +++++ src/xunitSettings.props | 8 +++++++ 8 files changed, 48 insertions(+), 25 deletions(-) create mode 100644 src/xunit.runner.json create mode 100644 src/xunitSettings.props diff --git a/build.fsx b/build.fsx index c3e5b00d..2b65f763 100644 --- a/build.fsx +++ b/build.fsx @@ -25,7 +25,7 @@ let output = __SOURCE_DIRECTORY__ @@ "bin" let outputTests = __SOURCE_DIRECTORY__ @@ "TestResults" let outputPerfTests = __SOURCE_DIRECTORY__ @@ "PerfResults" let outputBinaries = output @@ "binaries" -let outputBinariesNet461 = outputBinaries @@ "net461" +let outputBinariesNet461 = outputBinaries @@ "net471" let outputBinariesNetStandard = outputBinaries @@ "netstandard2.0" let outputBinariesNet = outputBinaries @@ "net5.0" let outputNuGet = output @@ "nuget" @@ -52,7 +52,7 @@ let versionSuffix = | str -> str // Configuration values for tests -let testNetFrameworkVersion = "net461" +let testNetFrameworkVersion = "net471" let testNetCoreVersion = "netcoreapp3.1" let testNetVersion = "net5.0" @@ -115,7 +115,8 @@ Target "RunTests" (fun _ -> let projects = match (isWindows) with | true -> !! "./src/**/*.Tests.csproj" - | _ -> !! "./src/**/*.Tests.csproj" // if you need to filter specs for Linux vs. Windows, do it here + | _ -> !! "./src/**/*.Tests.csproj" + -- "./src/**/*.API.Tests.csproj" // if you need to filter specs for Linux vs. Windows, do it here let runSingleProject project = let arguments = diff --git a/src/Hyperion.API.Tests/Hyperion.API.Tests.csproj b/src/Hyperion.API.Tests/Hyperion.API.Tests.csproj index f7b34d38..1c1c0aee 100644 --- a/src/Hyperion.API.Tests/Hyperion.API.Tests.csproj +++ b/src/Hyperion.API.Tests/Hyperion.API.Tests.csproj @@ -1,8 +1,9 @@ + - net461;netcoreapp3.1;net5.0 + $(NetFrameworkTestVersion);$(NetTestVersion);$(NetCoreTestVersion) false diff --git a/src/Hyperion.Akka.Integration.Tests/Hyperion.Akka.Integration.Tests.csproj b/src/Hyperion.Akka.Integration.Tests/Hyperion.Akka.Integration.Tests.csproj index 74d9689b..a0b6417d 100644 --- a/src/Hyperion.Akka.Integration.Tests/Hyperion.Akka.Integration.Tests.csproj +++ b/src/Hyperion.Akka.Integration.Tests/Hyperion.Akka.Integration.Tests.csproj @@ -1,8 +1,9 @@ + - net461;netcoreapp3.1;net5.0 + $(NetFrameworkTestVersion);$(NetTestVersion);$(NetCoreTestVersion) false diff --git a/src/Hyperion.Benchmarks/Hyperion.Benchmarks.csproj b/src/Hyperion.Benchmarks/Hyperion.Benchmarks.csproj index a3478263..59ec7d23 100644 --- a/src/Hyperion.Benchmarks/Hyperion.Benchmarks.csproj +++ b/src/Hyperion.Benchmarks/Hyperion.Benchmarks.csproj @@ -1,8 +1,8 @@ - + Exe - net461;netcoreapp3.1;net5.0 + $(NetFrameworkTestVersion);$(NetTestVersion);$(NetCoreTestVersion) false diff --git a/src/Hyperion.Tests/Hyperion.Tests.csproj b/src/Hyperion.Tests/Hyperion.Tests.csproj index 74a9b28e..6983f5f3 100644 --- a/src/Hyperion.Tests/Hyperion.Tests.csproj +++ b/src/Hyperion.Tests/Hyperion.Tests.csproj @@ -1,22 +1,30 @@  + Exe - net461;netcoreapp3.1;net5.0 + $(NetFrameworkTestVersion);$(NetTestVersion);$(NetCoreTestVersion) true latest Hyperion.Tests.Generator.Program - + $(DefineConstants);NETCOREAPP - + $(DefineConstants);NETFX + + + + true + + + @@ -30,9 +38,4 @@ - - - true - - diff --git a/src/common.props b/src/common.props index 260f7522..83c58bb9 100644 --- a/src/common.props +++ b/src/common.props @@ -2,22 +2,25 @@ Copyright © 2016-2021 Akka.NET Team Akka.NET Team - 0.9.17 - [Bump Microsoft.NET.Test.Sdk from 16.6.1 to 16.7.1](https://github.com/akkadotnet/Hyperion/pull/182) -[Fix unit test problem](https://github.com/akkadotnet/Hyperion/pull/191) -[Bump FSharp.Core from 4.7.2 to 5.0.0](https://github.com/akkadotnet/Hyperion/pull/189) -[Fix issue #40 regarding partial streams](https://github.com/akkadotnet/Hyperion/pull/185) -[Fix Hyperion not using known serializers when defined](https://github.com/akkadotnet/Hyperion/pull/184) -[Bump Microsoft.NET.Test.Sdk from 16.7.1 to 16.8.3](https://github.com/akkadotnet/Hyperion/pull/196) -[Bump System.Collections.Immutable from 1.7.1 to 5.0.0](https://github.com/akkadotnet/Hyperion/pull/195) -[Bump FSharp.Core from 5.0.0 to 5.0.1](https://github.com/akkadotnet/Hyperion/pull/202) -[Update the cross framework spec to include complex POCO object, Type serialization, and support for netcoreapp3.1 and net5.0](https://github.com/akkadotnet/Hyperion/pull/204) + 0.11.0 + [Fix array of user defined structs serialization failure](https://github.com/akkadotnet/Hyperion/pull/235) +[Remove dynamic keyword usage from array serializer](https://github.com/akkadotnet/Hyperion/pull/139) +[Change field ordering to ordinal](https://github.com/akkadotnet/Hyperion/pull/236) +Possible breaking changes** +The change to the object serializer field ordering might cause a deserialization failure of persisted objects +that are serialized using the Hyperion serializer. +Please report any serialization problem that occurs after an upgrade to this version at the +[issue tracker](https://github.com/akkadotnet/Hyperion/issues) http://getakka.net/images/akkalogo.png https://github.com/akkadotnet/Hyperion https://github.com/akkadotnet/Hyperion/blob/master/LICENSE $(NoWarn);CS1591 + netcoreapp3.1 + net5.0 + net471 + netstandard2.0 1.4.23 6.0.0 2.4.1 diff --git a/src/xunit.runner.json b/src/xunit.runner.json new file mode 100644 index 00000000..4a73b1e5 --- /dev/null +++ b/src/xunit.runner.json @@ -0,0 +1,6 @@ +{ + "$schema": "https://xunit.github.io/schema/current/xunit.runner.schema.json", + "longRunningTestSeconds": 60, + "parallelizeAssembly": false, + "parallelizeTestCollections": false +} \ No newline at end of file diff --git a/src/xunitSettings.props b/src/xunitSettings.props new file mode 100644 index 00000000..099c40f4 --- /dev/null +++ b/src/xunitSettings.props @@ -0,0 +1,8 @@ + + + + + Always + + + \ No newline at end of file