Sitelet https://github.com/npgsql/npgsql/pull/5945/files
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/native-aot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
matrix:
os: [ ubuntu-24.04 ]
pg_major: [ 15 ]
tfm: [ net8.0 ]
tfm: [ net9.0 ]

steps:
- name: Checkout
Expand Down Expand Up @@ -123,7 +123,7 @@ jobs:
matrix:
os: [ubuntu-24.04]
pg_major: [15]
tfm: [ net8.0 ]
tfm: [ net9.0 ]

steps:
- name: Checkout
Expand Down Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion test/MStatDumper/MStatDumper.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<!-- We need to override TargetFrameworks here to avoid build failures -->
<TargetFrameworks>net8.0</TargetFrameworks>
<TargetFrameworks>net9.0</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>disable</Nullable>
</PropertyGroup>
Expand Down
1 change: 1 addition & 0 deletions test/Npgsql.NativeAotTests/Npgsql.NativeAotTests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
<UseSystemResourceKeys>true</UseSystemResourceKeys>
<StackTraceSupport>false</StackTraceSupport>
<IlcFoldIdenticalMethodBodies>true</IlcFoldIdenticalMethodBodies>
<TrimmerSingleWarn>false</TrimmerSingleWarn>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="../../src/Npgsql/Npgsql.csproj" />
Expand Down
2 changes: 2 additions & 0 deletions test/Npgsql.Tests/ExceptionTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -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]
Expand Down Expand Up @@ -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
}