diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2bdd30de10..6c62460816 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,17 +31,21 @@ jobs: os: [ubuntu-24.04] pg_major: [17, 16, 15, 14, 13] config: [Release] - test_tfm: [net8.0] + test_tfm: [net9.0] include: - os: ubuntu-24.04 pg_major: 17 config: Debug - test_tfm: net8.0 + test_tfm: net9.0 - os: macos-15 pg_major: 16 config: Release - test_tfm: net8.0 + test_tfm: net9.0 - os: windows-2022 + pg_major: 17 + config: Release + test_tfm: net9.0 + - os: ubuntu-24.04 pg_major: 17 config: Release test_tfm: net8.0 diff --git a/.github/workflows/native-aot.yml b/.github/workflows/native-aot.yml index cd6498fd24..b3b2346a35 100644 --- a/.github/workflows/native-aot.yml +++ b/.github/workflows/native-aot.yml @@ -89,7 +89,7 @@ jobs: matrix: os: [ ubuntu-24.04 ] pg_major: [ 15 ] - tfm: [ net8.0 ] + tfm: [ net9.0 ] steps: - name: Checkout @@ -123,7 +123,7 @@ jobs: matrix: os: [ubuntu-24.04] pg_major: [15] - tfm: [ net8.0 ] + tfm: [ net9.0 ] steps: - name: Checkout @@ -163,11 +163,11 @@ jobs: - name: Write binary size to summary run: | - size="$(ls -l test/Npgsql.NativeAotTests/bin/Release/net8.0/linux-x64/native/Npgsql.NativeAotTests | cut -d ' ' -f 5)" + size="$(ls -l test/Npgsql.NativeAotTests/bin/Release/net9.0/linux-x64/native/Npgsql.NativeAotTests | cut -d ' ' -f 5)" echo "Binary size is $size bytes ($((size / (1024 * 1024))) mb)" >> $GITHUB_STEP_SUMMARY - name: Dump mstat - run: dotnet run --project test/MStatDumper/MStatDumper.csproj -c release -f ${{ matrix.tfm }} -- "test/Npgsql.NativeAotTests/obj/Release/net8.0/linux-x64/native/Npgsql.NativeAotTests.mstat" md >> $GITHUB_STEP_SUMMARY + run: dotnet run --project test/MStatDumper/MStatDumper.csproj -c release -f ${{ matrix.tfm }} -- "test/Npgsql.NativeAotTests/obj/Release/net9.0/linux-x64/native/Npgsql.NativeAotTests.mstat" md >> $GITHUB_STEP_SUMMARY - name: Upload mstat uses: actions/upload-artifact@v4 diff --git a/test/MStatDumper/MStatDumper.csproj b/test/MStatDumper/MStatDumper.csproj index 3cab4d57fd..456bd1f3b9 100644 --- a/test/MStatDumper/MStatDumper.csproj +++ b/test/MStatDumper/MStatDumper.csproj @@ -3,7 +3,7 @@ Exe - net8.0 + net9.0 enable disable diff --git a/test/Npgsql.NativeAotTests/Npgsql.NativeAotTests.csproj b/test/Npgsql.NativeAotTests/Npgsql.NativeAotTests.csproj index 31831faded..0757fb0dd6 100644 --- a/test/Npgsql.NativeAotTests/Npgsql.NativeAotTests.csproj +++ b/test/Npgsql.NativeAotTests/Npgsql.NativeAotTests.csproj @@ -9,6 +9,7 @@ true false true + false diff --git a/test/Npgsql.Tests/ExceptionTests.cs b/test/Npgsql.Tests/ExceptionTests.cs index 21d83ff9fb..b58617ef52 100644 --- a/test/Npgsql.Tests/ExceptionTests.cs +++ b/test/Npgsql.Tests/ExceptionTests.cs @@ -210,6 +210,7 @@ public void NpgsqlException_IsTransient() Assert.False(new NpgsqlException("", new Exception("Inner Exception")).IsTransient); } +#if !NET9_0_OR_GREATER #pragma warning disable SYSLIB0051 #pragma warning disable 618 [Test] @@ -309,4 +310,5 @@ public void Base_exception_property_serialization() Assert.That(ex.StackTrace, Is.EqualTo(info.GetValue("StackTraceString", typeof(string)))); } #pragma warning restore SYSLIB0051 +#endif }