Skip to content

test: run the EF suites on the newest EF Core / Npgsql EF 10 patch as well as the floor - #311

Merged
CaffeinatedCoder merged 2 commits into
release/10.xfrom
test/297-ef-newest-patch-leg
Oct 19, 2026
Merged

CaffeinatedCoder merged 2 commits into
release/10.xfrom
test/297-ef-newest-patch-leg

Conversation

@CaffeinatedCoder

@CaffeinatedCoder CaffeinatedCoder commented Oct 19, 2026 •

Copy link
Copy Markdown
Owner

Closes #297

Closes acts only on main, so #297 is closed by hand after this merges into release/10.x.

Problem

The EF test projects only ever ran on the floor the packages ship against: Npgsql EF 10.0.0, which resolves EF Core 10.0.0. A consumer's application resolves the newest patch, and Npgsql EF 10.0.1–10.0.3 require EF Core 10.0.4 or newer. CI never saw what consumers run. #302 came in through that gap: green on every floor run, while every Any/Count over an empty captured list failed on the server on EF Core 10.0.2 and later.

Change

  • test/Directory.Build.targets (new; there is no root Directory.Build.targets to shadow). When -p:EfFloat=… -p:NpgsqlEfFloat=… are passed, every test project whose name contains EFCore gets Microsoft.EntityFrameworkCore, .Relational, Npgsql.EntityFrameworkCore.PostgreSQL and .PostgreSQL.NodaTime at those versions, and Microsoft.EntityFrameworkCore.Design is updated to match. Direct references win, so the test hosts load the newer assemblies while src/ keeps compiling against the floor, which is a consumer's situation. Without the properties nothing changes.
  • .github/workflows/dotnet.yml: integration-legs gains an ef axis (floor, newest-patch). The newest published versions (EF Core 10.0.13, Npgsql EF 10.0.3) sit in one matrix include, with a comment on how to look them up, so a new patch is a one-line bump.
    • The newest-patch legs run all four EF projects on PostgreSQL 16 and 18, with the same container setup as the floor legs.
    • Before testing, each newest-patch leg checks that every EF test host's deps.json names the versions it asked for. A float that stopped reaching the hosts (a renamed property or project) would otherwise test the floor twice and pass.
    • The test loop runs every project before it fails, on the floor legs too. The step's shell stops at the first failing command, which hid the translation failures behind the integration ones; see Tests.
    • Leg names: Integration (PostgreSQL 16, EF Core floor), Integration (PostgreSQL 16, EF Core 10.0.13), and the same for 18.
    • Required: the Integration (live PostgreSQL) gate needs every leg, so the new legs are required without any ruleset change. The floor legs and the Test (ubuntu-latest) floor run stay required as before.
  • CONTRIBUTING.md, AGENTS.md: how to run the float locally and where the versions live.
  • .github/dependabot.yml is unchanged. The leg floats explicitly, and a Dependabot bump would raise the shipping floor.

Not here: the scheduled run against EF Core's servicing builds. The dnceng dotnet10 feed answers, but holds only 10.0.0 prereleases (newest 10.0.0-rtm.25513.102). Also, GitHub fires schedule only from the default branch, so a trigger on release/10.x would never run. The servicing builds are on the per-build darc-pub-dotnet-dotnet-<sha> feed that dotnet/efcore release/10.0's NuGet.config names. The four EF projects pass against the staged 10.0.14 there. #297 records what was tried; the scheduled run is #312.

Tests

Proven by reverting the #302 fix: EmptyCollectionRewriter.cs from PR #306, back to d883b12^. All runs are local on release/10.x, with Docker and PostgreSQL 16 and DOTNET_CLI_UI_LANGUAGE=en.

Newest patch (-p:EfFloat=10.0.13 -p:NpgsqlEfFloat=10.0.3), fix reverted: red, exactly #302's nine.

CodoMetis.ValueRanges.EFCore.PostgreSQL.Tests
  Failed AnyAlone_OverAnEmptyCapturedList_ReadsNoRows
  Failed AnyBesideContains_OverAnEmptyCapturedList_ReadsNoRows
  Failed Any_OverAnEmptyCapturedList_ReadsNoRows
  Failed Count_OverAnEmptyCapturedList_ReadsNoRows
Failed!  - Failed:     4, Passed:   291, Skipped:     0, Total:   295
CodoMetis.ValueRanges.EFCore.PostgreSQL.IntegrationTests
  Failed AnEmptyCollection_AnyAndCountAnswerAsInMemory      (Npgsql.PostgresException: 42883: operator does not exist: text && text[])
  Failed AnEmptyCollectionAlone_AnyAndCountAnswerAsInMemory
  Failed AnEmptyCollectionBesideContains_AnyAndCountAnswerAsInMemory
  Failed Ranges_AnswerAsInMemory
  Failed ValueSets_AnswerAsInMemory
Failed!  - Failed:     5, Passed:   275, Skipped:     0, Total:   280
CodoMetis.ValueRanges.EFCore.PostgreSQL.NodaTime.Tests                 Passed!  - Failed: 0, Passed:  91, Total:  91
CodoMetis.ValueRanges.EFCore.PostgreSQL.InfinityDisabled.IntegrationTests Passed!  - Failed: 0, Passed:   4, Total:   4
resolved: Microsoft.EntityFrameworkCore/10.0.13, Microsoft.EntityFrameworkCore.Relational/10.0.13, Npgsql.EntityFrameworkCore.PostgreSQL/10.0.3 (Design/10.0.13 where referenced)

Floor, same checkout, fix still reverted: green.

CodoMetis.ValueRanges.EFCore.PostgreSQL.Tests                          Passed!  - Failed: 0, Passed: 295, Total: 295
CodoMetis.ValueRanges.EFCore.PostgreSQL.IntegrationTests               Passed!  - Failed: 0, Passed: 280, Total: 280
CodoMetis.ValueRanges.EFCore.PostgreSQL.NodaTime.Tests                 Passed!  - Failed: 0, Passed:  91, Total:  91
CodoMetis.ValueRanges.EFCore.PostgreSQL.InfinityDisabled.IntegrationTests Passed!  - Failed: 0, Passed:   4, Total:   4
resolved: Microsoft.EntityFrameworkCore/10.0.0, Microsoft.EntityFrameworkCore.Relational/10.0.0, Npgsql.EntityFrameworkCore.PostgreSQL/10.0.0

Newest patch with the fix in place: the CI steps replayed under bash (solution restore and build with the properties, the deps.json check, --no-build tests). All four hosts resolve EF Core 10.0.13 and Npgsql EF 10.0.3, and the projects pass 295/295, 280/280, 91/91 and 4/4.

The deps.json check, seeded: run against floor-built test hosts, it fails with ::error::…InfinityDisabled.IntegrationTests.deps.json does not resolve Microsoft.EntityFrameworkCore/10.0.13, so this leg would test the floor.

Conventions: 403/403 with the change. TheRequiredChecks_AreStillJobNames and TheIntegrationGate_PassesOnlyWhenEveryLegPassed read this workflow.

On CI, with a temporary commit on top that reverted the #302 rewriter. The commit was pushed, run, and dropped; it is not in the branch.

  • Run 39254215067 on 74820ee = 2fd2d32 + revert: the newest-patch legs red, the floor green.
    • Integration (PostgreSQL 16, EF Core 10.0.13) and (PostgreSQL 18, EF Core 10.0.13) both ran the deps.json check first and passed it: all four hosts resolve EF Core 10.0.13 and Npgsql EF 10.0.3. Then each failed the same nine:
      ==> test/CodoMetis.ValueRanges.EFCore.PostgreSQL.InfinityDisabled.IntegrationTests/
      Passed!  - Failed:     0, Passed:     4, Skipped:     0, Total:     4
      ==> test/CodoMetis.ValueRanges.EFCore.PostgreSQL.IntegrationTests/
        Failed Ranges_AnswerAsInMemory
        Failed ValueSets_AnswerAsInMemory
        Failed AnEmptyCollectionBesideContains_AnyAndCountAnswerAsInMemory
        Failed AnEmptyCollectionAlone_AnyAndCountAnswerAsInMemory
        Failed AnEmptyCollection_AnyAndCountAnswerAsInMemory
      Failed!  - Failed:     5, Passed:   275, Skipped:     0, Total:   280
      ==> test/CodoMetis.ValueRanges.EFCore.PostgreSQL.NodaTime.Tests/
      Passed!  - Failed:     0, Passed:    91, Skipped:     0, Total:    91
      ==> test/CodoMetis.ValueRanges.EFCore.PostgreSQL.Tests/
        Failed AnyAlone_OverAnEmptyCapturedList_ReadsNoRows
        Failed AnyBesideContains_OverAnEmptyCapturedList_ReadsNoRows
        Failed Any_OverAnEmptyCapturedList_ReadsNoRows
        Failed Count_OverAnEmptyCapturedList_ReadsNoRows
      Failed!  - Failed:     4, Passed:   291, Skipped:     0, Total:   295
      
    • Integration (PostgreSQL 16, EF Core floor) and (PostgreSQL 18, EF Core floor) are green: 4/4 and 280/280. Test (ubuntu-latest) (the floor translation projects) and Consumer smoke test are green. Integration (live PostgreSQL) is red, so the newest-patch legs block a merge.
  • Run 39253722759, the first try with the revert, showed the same split but stopped each newest-patch leg after the integration project. The step's shell runs with -e, and the glob puts the translation projects last, so their four failures never showed. The loop now runs every project before failing.
  • Run 39254658585 on 2fd2d32, the branch as it is, with no revert: every check green. Integration (PostgreSQL 16, EF Core 10.0.13) resolves EF Core 10.0.13 and Npgsql EF 10.0.3 in all four hosts and passes 4/4, 280/280, 91/91 and 295/295; PostgreSQL 18 passes the same. Both floor legs, Test (ubuntu-latest), Integration (live PostgreSQL), Pack and Consumer smoke test pass.

🤖 Generated with Claude Code

@CaffeinatedCoder CaffeinatedCoder added this to the 10.1.0 milestone Oct 19, 2026
@CaffeinatedCoder CaffeinatedCoder added tests Adds or changes tests only (oracles, harnesses); no library code package/efcore Affects CodoMetis.ValueRanges.EFCore.PostgreSQL area/release Versioning, changelogs, release wiring package/efcore-nodatime Affects CodoMetis.ValueRanges.EFCore.PostgreSQL.NodaTime labels Oct 19, 2026
… well as the floor

The EF test projects only ever ran on the floor the packages ship against (Npgsql EF
10.0.0, which resolves EF Core 10.0.0), while a consumer's application resolves the
newest patch: Npgsql EF 10.0.1-10.0.3 require EF Core >= 10.0.4. #302 came in through
that gap, green on every floor run and failing on the server on every patch from
EF Core 10.0.2 on.

test/Directory.Build.targets floats the EF test projects (every project whose name
contains EFCore) when -p:EfFloat and -p:NpgsqlEfFloat are passed: it adds EF Core,
Relational, Npgsql EF and Npgsql EF NodaTime at those versions and updates Design to
match. Direct references win, so the test hosts load the newer assemblies while src/
still compiles against the floor, which is a consumer's situation. Without the
properties nothing changes. There is no root Directory.Build.targets to shadow, the
consumer smoke test builds outside the repository, and the conventions suite passes
unchanged (403/403).

dotnet.yml's integration-legs matrix gains an ef axis, floor and newest-patch, and the
newest published versions (EF Core 10.0.13, Npgsql EF 10.0.3) sit in one matrix include,
so a new patch is a one-line bump. The newest-patch legs run all four EF projects on
PostgreSQL 16 and 18, reusing the legs' container setup, and first check that every EF
test host's deps.json names the versions asked for, so a float that stops reaching the
hosts fails instead of testing the floor twice. The test loop runs every
project before failing, as the step's shell stops at the first failing command and
the glob puts the translation projects after the integration ones; a first CI run
with the fix reverted stopped after the integration project and never showed the
four translation failures. The "Integration (live PostgreSQL)" gate
needs every leg, so the new legs are required with no ruleset change, and the floor
legs stay required as they were.

No scheduled run against EF Core's servicing builds: the dnceng dotnet10 feed holds
only 10.0.0 prereleases (newest 10.0.0-rtm.25513.102), and GitHub fires schedule only
from the default branch. #297 records what was tried.

Proof, locally on release/10.x with the #302 fix (EmptyCollectionRewriter.cs from
PR #306) reverted to d883b12^:
- float (10.0.13 / 10.0.3): translation 291/295 (the four empty-captured-list tests),
  integration 275/280 (#302's five, 42883: operator does not exist: text && text[]),
  NodaTime translation 91/91, InfinityDisabled 4/4
- floor: 295/295, 280/280, 91/91, 4/4
With the fix in place, the CI steps replayed under bash pass on the float: 295, 280,
91, 4.

Issue #297, on release/10.x only; closed by hand after the merge, since a closing
keyword acts only on main.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@CaffeinatedCoder
CaffeinatedCoder force-pushed the test/297-ef-newest-patch-leg branch 2 times, most recently from 74820ee to 2fd2d32 Compare October 19, 2026 12:46
@CaffeinatedCoder CaffeinatedCoder mentioned this pull request Oct 19, 2026
@CaffeinatedCoder
CaffeinatedCoder merged commit b9d7fa2 into release/10.x Oct 19, 2026
@CaffeinatedCoder
CaffeinatedCoder deleted the test/297-ef-newest-patch-leg branch October 19, 2026 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/release Versioning, changelogs, release wiring package/efcore Affects CodoMetis.ValueRanges.EFCore.PostgreSQL package/efcore-nodatime Affects CodoMetis.ValueRanges.EFCore.PostgreSQL.NodaTime tests Adds or changes tests only (oracles, harnesses); no library code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant