Skip to content

Fix Aether stub downloader test isolation#2496

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

Fix Aether stub downloader test isolation#2496
hutiefang76 wants to merge 1 commit into
spring-cloud: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-cloudgh-2478

Signed-off-by: hutiefang <hutiefang@qq.com>
@hutiefang76 hutiefang76 force-pushed the codex/scc-2478-aether-test-isolation branch from b8ecb4f to 321b9bf Compare June 24, 2026 16:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AetherStubDownloaderSpec fails if maven install is not run

2 participants