Maven - Different Dependency Version in Test

前端 未结 2 1228
清歌不尽
清歌不尽 2021-01-25 11:19

I\'m suffering an issue similar to Maven 2 - different dependency versions in test and compile but the specified answer there does not work.

In my project I need to depe

2条回答
  •  执念已碎
    2021-01-25 11:53

    Looks like a maven bug - or if not, something that is fishy enough I wouldn't trust the documentation if there were any.

    In your case, I would probably:

    1. upgrade maven and see if the issue is fixed in the latest m3
    2. try repackaging one of the hadoop versions with another artifact id or group name. maven-shade-plugin, don't bother changing the package name, but just introduce something maven won't know is no different from org.apache.hadoop:hadoop-core
    3. try moving the tests to a separate project downstream
    4. start debugging maven and understand what's going on exactly (and then fall back on 1 or 2...)

提交回复
热议问题