mirror of
https://github.com/azaion/missions.git
synced 2026-06-21 11:41:07 +00:00
3398ec49a0
ci/woodpecker/push/build-arm Pipeline was successful
- Updated Azaion.Missions.csproj to exclude test sources from service compilation, preventing build failures due to test project dependencies. - Modified docker-compose.test.yml to preload the pg_stat_statements extension for testing and adjusted JWT refresh intervals for better test execution timing. - Enhanced Dockerfile to install wget for health checks and ensure proper initialization of the container. - Introduced a test-only endpoint for JWKS refresh to facilitate end-to-end testing without relying on the default refresh intervals. - Updated DTOs in ApiDtos.cs to reflect camelCase naming conventions for consistency with service responses. - Improved test cases to handle JWKS rotation and refresh scenarios effectively, ensuring robust validation of JWT handling. This commit lays the groundwork for more reliable and efficient testing of the Azaion.Missions project.
15 lines
909 B
C#
15 lines
909 B
C#
// JWKS rotation, JWKS refresh, and DbResetFixture all mutate process-wide
|
|
// state on the shared `missions-sut` container (the JWKS cache, the database,
|
|
// the CORS warm-up flag, etc.). xUnit runs different [Collection(...)] groups
|
|
// in parallel by default, which races those mutations against any test that
|
|
// happens to mint a token or query a row at the same moment. The whole e2e
|
|
// surface is one System-Under-Test; serializing the collections is the only
|
|
// way to make assertions deterministic.
|
|
//
|
|
// We still keep [Collection(...)] attributes per class — they continue to
|
|
// enforce intra-collection ordering and let xUnit fail fast if two tests in
|
|
// the same fixture race. DisableTestParallelization=true switches the
|
|
// across-collection scheduling off; intra-collection serialization is the
|
|
// default and still applies.
|
|
[assembly: Xunit.CollectionBehavior(DisableTestParallelization = true)]
|