ci: relax dotnet format gate to severity=error#24
Merged
Extentsoftware merged 6 commits intomainfrom May 10, 2026
Merged
Conversation
Format verification was running at --severity warn, so the gate failed on every analyzer warning surfaced by xunit.analyzers (xUnit1051) even though those are not formatting issues. Restrict the gate to actual errors; the build step still treats warnings as errors and remains the authority for analyzer hygiene. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Build runs with TreatWarningsAsErrors=true, which surfaces analyzer warnings that aren't load-bearing for test code: - xUnit1051 (use TestContext.Current.CancellationToken) — ~75 sites - IDE0005 (remove unused usings) — handful in test files - CA1711 (avoid 'Collection' suffix) — required by xUnit fixture convention Add a tests/.editorconfig that disables these for the test tree only. Also pass the image to MsSqlBuilder via its constructor; the parameterless ctor is obsolete in Testcontainers.MsSql. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Two pre-existing test regressions on main, both about read-after-write shape: - Workflow round-trip: EF materialises the owned _steps collection in physical row order, which is not guaranteed to match insertion order. Sort by the existing Order field at the domain boundary so callers always see steps in workflow order. - Outbox round-trip: the MarkProcessed test inserts a "Test.Event" and flips ProcessedAt; that row leaked into the persistence test's AllSatisfy assertion via the shared MSSQL container. Narrow the query to the event types this test actually writes. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Program.cs reads the connection string from LOOM_CONNECTION (or the configured value) before WebApplicationFactory's ConfigureAppConfiguration hook runs, so the InMemory override in LoomWebFactory was being shadowed by appsettings.Development.json's SQL Server connection string and the host smoke tests tried to connect to localhost:1433. Set LOOM_CONNECTION in the factory constructor to the temp SQLite path so the auto-detected provider matches the SQLite-only fixture model.
ExternalId pinned its column type to nvarchar(max), which SQLite can't parse and caused EnsureCreated to throw 'near "max": syntax error' in the Loom.Web smoke tests. Removing the explicit type lets the provider choose the right unbounded text type (nvarchar(max) on SQL Server, TEXT on SQLite); behaviour on SQL Server is unchanged.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
🤖 Generated with Claude Code