mockito / mockito-kotlin

Using Mockito with Kotlin
MIT License
3.11k stars 202 forks source link

Mockito-core test scope forces byte-buddy compile scope into module #333

Closed Gerromie closed 5 years ago

Gerromie commented 5 years ago

Adding mockito-core to a maven module in test scope results in byte-buddy being brought in as a transient dependency in compile scope. This incorrectly changes any version of byte-buddy that might have been used by other modules (such as via swagger).

This appears on all versions of mockito-core tried from 2.18.3 up to 2.25.0.

It's expected that the test scope of mockito-core may use transient dependencies in the same scope but that the inclusion of the module would not override compile scope versions.

Gerromie commented 5 years ago

I didn't realize this earlier, but I had navigated to the wrong project. This should have been filed against mocking directly.