Skip to content

Sync to EF Core preview.6#3860

Open
roji wants to merge 13 commits into
npgsql:mainfrom
roji:roji/update-ef-preview6
Open

Sync to EF Core preview.6#3860
roji wants to merge 13 commits into
npgsql:mainfrom
roji:roji/update-ef-preview6

Conversation

@roji

@roji roji commented Jun 14, 2026

Copy link
Copy Markdown
Member

This syncs the provider to the latest EF Core preview.6 build so EFCore.PG can continue tracking the current EF 11 preview train.

Changes

  • Bump the provider version and EF/Microsoft.Extensions dependencies to preview.6.
  • Pin the .NET 11 preview.6 SDK/runtime and enable Microsoft.Testing.Platform for test execution.
  • Migrate test infrastructure to xUnit v3, including async lifetime updates and provider-specific skip traits.
  • Update provider tests and SQL baselines for preview.6 query pipeline changes.
  • Fix preview.6 compatibility issues around JSON update SQL generation, connection creation interception, TPC generated-key seeding, value converter timestamp mappings, and provider-specific FromSql behavior.

Validation

  • dotnet build EFCore.PG.slnx --no-restore -v:minimal -m:1
  • dotnet exec test/EFCore.PG.Tests/bin/Debug/net11.0/Npgsql.EntityFrameworkCore.PostgreSQL.Tests.dll --filter-not-trait category=failing --no-progress --timeout 5m
  • dotnet exec test/EFCore.PG.FunctionalTests/bin/Debug/net11.0/Npgsql.EntityFrameworkCore.PostgreSQL.FunctionalTests.dll --filter-not-trait category=failing --max-threads 4 --timeout 30m --long-running 120 --no-progress

roji and others added 5 commits April 19, 2022 12:51
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 14, 2026 21:37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR syncs EFCore.PG to EF Core 11 preview.6, updating provider and test infrastructure to stay aligned with the EF 11 preview train and its query/update pipeline changes.

Changes:

  • Bumps EF Core / Microsoft.Extensions package versions to 11.0.0-preview.6.*, updates provider version prefix, and pins the .NET 11 preview.6 SDK via global.json.
  • Migrates tests to xUnit v3 + Microsoft.Testing.Platform runner and updates various fixtures/lifetimes accordingly.
  • Updates multiple functional tests and SQL baselines to match preview.6 behaviors (query SQL shape, bulk update SQL, JSON update SQL generation, etc.).
Show a summary per file
File Description
test/EFCore.PG.FunctionalTests/ValueConvertersEndToEndNpgsqlTest.cs Updates DateTime conversion expectations and explicitly configures timestamp column types.
test/EFCore.PG.FunctionalTests/Update/JsonUpdateNpgsqlTest.cs Removes redundant conditional attributes on JSON update tests.
test/EFCore.PG.FunctionalTests/TestUtilities/RequiresPostgisAttribute.cs Converts PostGIS requirement into a trait-based “failing” categorization for filtering under xUnit v3.
test/EFCore.PG.FunctionalTests/TestUtilities/MinimumPostgresVersionAttribute.cs Converts minimum PostgreSQL version requirement into a trait-based “failing” categorization for filtering under xUnit v3.
test/EFCore.PG.FunctionalTests/SequenceEndToEndTest.cs Updates async lifetime methods to return ValueTask (xUnit v3 pattern).
test/EFCore.PG.FunctionalTests/Scaffolding/NpgsqlDatabaseModelFactoryTest.cs Updates fixture async initialization signature to ValueTask.
test/EFCore.PG.FunctionalTests/Query/UdfDbFunctionNpgsqlTests.cs Removes a conditional skip for a RELEASE-only test override.
test/EFCore.PG.FunctionalTests/Query/Translations/MathTranslationsNpgsqlTest.cs Updates SQL assertions to include additional SQL statements for Sign translations.
test/EFCore.PG.FunctionalTests/Query/Translations/ByteArrayTranslationsNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/SqlQueryNpgsqlTest.cs Unskips several tests and updates SQL baselines/parameter naming for preview.6 behavior.
test/EFCore.PG.FunctionalTests/Query/PrimitiveCollectionsQueryNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/NorthwindGroupByQueryNpgsqlTest.cs Updates SQL baseline (alias changes) and removes a skip.
test/EFCore.PG.FunctionalTests/Query/NorthwindDbFunctionsQueryNpgsqlTest.cs Updates platform skip attribute usage for preview.6/xUnit v3.
test/EFCore.PG.FunctionalTests/Query/LegacyTimestampQueryTest.cs Updates async disposal to ValueTask and simplifies completion.
test/EFCore.PG.FunctionalTests/Query/Inheritance/TPCInheritanceQueryNpgsqlTest.cs Removes a provider-specific override that expected a key conflict, aligning with updated seeding.
test/EFCore.PG.FunctionalTests/Query/Inheritance/TPCInheritanceQueryNpgsqlFixture.cs Adds seeding logic to advance the TPC sequence after manual inserts.
test/EFCore.PG.FunctionalTests/Query/FromSqlQueryNpgsqlTest.cs Reworks invalid-cast tests to use provider-specific SQL and assertions.
test/EFCore.PG.FunctionalTests/Query/EntitySplittingQueryNpgsqlTest.cs Re-enables previously skipped tests and adds explicit SQL baselines.
test/EFCore.PG.FunctionalTests/Query/ComplexNavigationsSharedTypeQueryNpgsqlTest.cs Removes skips for previously failing query scenarios.
test/EFCore.PG.FunctionalTests/Query/CompatibilityQueryNpgsqlTest.cs Updates async lifetime methods to ValueTask.
test/EFCore.PG.FunctionalTests/Query/Associations/OwnedNavigations/OwnedNavigationsCollectionNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/Associations/OwnedJson/OwnedJsonCollectionNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/Associations/Navigations/NavigationsCollectionNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/Associations/ComplexJson/ComplexJsonCollectionNpgsqlTest.cs Removes redundant conditional attribute from an override.
test/EFCore.PG.FunctionalTests/Query/AdHocMiscellaneousQueryNpgsqlTest.cs Re-enables a UDF store-type test and adds a provider-specific DbContext/model setup.
test/EFCore.PG.FunctionalTests/Migrations/MigrationsNpgsqlTest.cs Removes skips for converter-related primitive collection migration tests.
test/EFCore.PG.FunctionalTests/Migrations/MigrationsInfrastructureNpgsqlTest.cs Removes temporary skips on migration apply/revert tests.
test/EFCore.PG.FunctionalTests/LazyLoadProxyNpgsqlTest.cs Removes conditional attributes around tests that were previously annotated as MARS-related.
test/EFCore.PG.FunctionalTests/JsonTypesNpgsqlTest.cs Removes redundant conditional attributes from JSON tests.
test/EFCore.PG.FunctionalTests/CustomConvertersNpgsqlTest.cs Removes a skip around DateTimeOffset-related test override.
test/EFCore.PG.FunctionalTests/ConvertToProviderTypesNpgsqlTest.cs Removes a skip around DateTimeOffset-related test override.
test/EFCore.PG.FunctionalTests/ConnectionInterceptionNpgsqlTest.cs Re-enables and reimplements connection creation interception tests; adjusts provider configuration.
test/EFCore.PG.FunctionalTests/ComputedColumnTest.cs Updates async lifetime methods to ValueTask.
test/EFCore.PG.FunctionalTests/BulkUpdates/NorthwindBulkUpdatesNpgsqlTest.cs Updates bulk update SQL baselines and adjusts assertions for nullable navigation results.
test/EFCore.PG.FunctionalTests/BuiltInDataTypesNpgsqlTest.cs Removes a skip around DateTimeOffset-related test override.
test/Directory.Build.props Switches tests to Microsoft.Testing.Platform runner and updates xUnit package references/usings/analyzer suppressions.
src/EFCore.PG/Update/Internal/NpgsqlUpdateSqlGenerator.cs Minor refactor around JSON path indices extraction with added debug assertion.
global.json Pins .NET 11 preview.6 SDK and configures Microsoft.Testing.Platform as the test runner.
Directory.Packages.props Bumps EF/Microsoft.Extensions versions to preview.6 and updates xUnit package versions to v3 prereleases.
Directory.Build.props Bumps VersionPrefix to 11.0.0-preview.6.

Copilot's findings

  • Files reviewed: 41/42 changed files
  • Comments generated: 2

Comment thread test/EFCore.PG.FunctionalTests/ConnectionInterceptionNpgsqlTest.cs
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 14, 2026 21:44
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 42/43 changed files
  • Comments generated: 3

Comment thread test/EFCore.PG.FunctionalTests/Query/AdHocMiscellaneousQueryNpgsqlTest.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/RequiresPostgisAttribute.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/MinimumPostgresVersionAttribute.cs Outdated
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 14, 2026 23:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 42/43 changed files
  • Comments generated: 3

Comment thread test/EFCore.PG.FunctionalTests/Query/AdHocMiscellaneousQueryNpgsqlTest.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/RequiresPostgisAttribute.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/MinimumPostgresVersionAttribute.cs Outdated
roji and others added 2 commits June 15, 2026 11:02
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 15, 2026 09:19

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 42/43 changed files
  • Comments generated: 5

Comment thread test/EFCore.PG.FunctionalTests/Query/FromSqlQueryNpgsqlTest.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/BulkUpdates/NorthwindBulkUpdatesNpgsqlTest.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/RequiresPostgisAttribute.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/TestUtilities/MinimumPostgresVersionAttribute.cs Outdated
Comment thread test/EFCore.PG.FunctionalTests/Query/SqlQueryNpgsqlTest.cs
roji and others added 2 commits June 15, 2026 11:34
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Mirror EF Core's trait-based conditional test attribute pattern, remove leftover inherited test data attributes, and document unsupported SQL query invalid-cast overrides.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 15, 2026 09:52

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 42/43 changed files
  • Comments generated: 2

Comment on lines 116 to 118
- name: Test
run: dotnet test -c ${{ matrix.config }} --logger "GitHubActions;report-warnings=false"
run: dotnet test -c ${{ matrix.config }} --filter-not-trait category=failing
shell: bash
Comment on lines +5 to +8
/// <summary>
/// Marks tests as requiring PostGIS. When PostGIS is not available, the attribute contributes a
/// <c>category=failing</c> trait so that the test runner can exclude the affected tests.
/// </summary>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants