spring-boot-resttestclient is missing test scope in spring-cloud-gateway-proxyexchange-webmvc
envgap__spring-cloud__spring-cloud-gateway-4256
01 / FAILURE SIGNATURE
As reported upstream
No identifying execution failure has been captured.
Not a benchmark task.
- The project already builds and runs before the fix, so there is nothing to repair.
02 / ENVIRONMENT RECIPE
- Base commit
745b86df30b055590b81b4c609984f11dee88d8a- Manifest
spring-cloud-gateway-proxyexchange-webmvc/pom.xml- Reproduce
Awaiting issue-specific recipe- Run under trace
Awaiting a meaningful runtime command
03 / ORIGINAL ISSUE TEXT
spring-cloud/spring-cloud-gateway #4256 · read the original issue
**Describe the bug** `spring-cloud-gateway-proxyexchange-webmvc` declares `org.springframework.boot:spring-boot-resttestclient` without a scope, so it defaults to `compile` and leaks onto the compile/runtime classpath of every application that depends on the module. It is only used by tests — `RestTestClient` appears in `src/test/java` and nowhere in `src/main/java`. Every other module in the repo already scopes it to `test` (`spring-cloud-gateway-server-webmvc`, `spring-cloud-gateway-server-webflux`, `spring-cloud-gateway-proxyexchange-webflux`), so this module looks like an oversight. **Sample** `mvn dependency:tree` on a project depending on `spring-cloud-gateway-proxyexchange-webmvc` shows `spring-boot-resttestclient` under `compile`. Adding `<scope>test</scope>` to the dependency fixes it; the module's tests still pass.
04 / LABELS
Labels from the report text only; not yet run
No supported category has been assigned.
Label rules and the text that matched
[]