Skip to content

Test the uptodate goals' mappers in unit tests - #274

Merged
slachiewicz merged 1 commit into
masterfrom
agent/uptodate-unit-tests
Nov 8, 2026
Merged

slachiewicz merged 1 commit into
masterfrom
agent/uptodate-unit-tests

Conversation

@slachiewicz

Copy link
Copy Markdown
Member

Eight ITs ran a build with -X per mapper type (flatten, glob, identity, merge, package, unpackage, and all six at once, up to date and out of date) only to grep which value uptodate-property or uptodate-properties defined. UpToDatePropertyTest builds the same file trees with FixtureUtils from the same fixture.properties, moved to src/test/resources/uptodate byte for byte, runs the goals with the same settings, and asserts each property's value. Seven ITs go; uptodate-multi stays as the IT for the family.

The test was generated from the IT POMs and verify scripts, so its settings and expected values are the ones the ITs encoded.

Verified: mvn -Prun-its verify on Maven 3.10.0-rc-1 → 88 unit tests and 45 ITs pass, uptodate-multi also on 4.0.0-rc-7; inverting the timestamp comparison fails the seven up-to-date tests, and dropping the else value fails the out-of-date one.

Part of mojohaus/.github#29

Seven ITs ran a build per mapper type to grep the defined property.
UpToDatePropertyTest builds the same file trees with FixtureUtils and
asserts the property values; uptodate-multi stays as the IT that covers
all mappers through the uptodate-properties goal.
@slachiewicz slachiewicz added the maintenance Cleanup, refactoring or other internal change label Nov 8, 2026
@slachiewicz
slachiewicz marked this pull request as ready for review November 8, 2026 01:07
@slachiewicz
slachiewicz merged commit 6bb6dca into master Nov 8, 2026
18 checks passed
@slachiewicz
slachiewicz deleted the agent/uptodate-unit-tests branch November 8, 2026 01:16
@github-actions github-actions Bot added this to the 3.7.1 milestone Nov 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Cleanup, refactoring or other internal change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant