Skip to content
This repository was archived by the owner on Jul 7, 2026. It is now read-only.

Fix Aether stub downloader test isolation#2496

Open
hutiefang76 wants to merge 1 commit into
spring-attic:mainfrom
hutiefang76:codex/scc-2478-aether-test-isolation
Open

Fix Aether stub downloader test isolation#2496
hutiefang76 wants to merge 1 commit into
spring-attic:mainfrom
hutiefang76:codex/scc-2478-aether-test-isolation

Conversation

@hutiefang76

Copy link
Copy Markdown

Fixes gh-2478

This re-enables AetherStubDownloaderSpec by removing the class-level @Ignore and making the remote-missing-artifact test self-contained.

Before this change, the test asserted that spring-cloud-contract-spec was already present in the developer's local Maven repository. That made the spec fail on a clean checkout unless a broader mvn install had been run first.

The test now uses the stub-runner module's existing m2repo test fixture as the configured local repository, while keeping the remote repository empty. This preserves the original assertion that remote mode should not accidentally resolve from the configured local repository when the remote artifact is missing, without depending on machine-local Maven state.

Verification:

JAVA_HOME=$(/usr/libexec/java_home -v 17) ./mvnw -pl spring-cloud-contract-stub-runner -Dtest=AetherStubDownloaderSpec test

Result: Tests run: 4, Failures: 0, Errors: 0, Skipped: 0 and BUILD SUCCESS.

Fixes spring-atticgh-2478

Signed-off-by: hutiefang <hutiefang@qq.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Development

Successfully merging this pull request may close these issues.

AetherStubDownloaderSpec fails if maven install is not run

2 participants