I had a problem when I have an old version of the Foo library as a transitive dependency in one of my included libraries. I want to use the newer version of the Foo library in my testCompile, but this causes a conflict when running tests in intelliJ, since intelliJ uses the older Foo lib by default.
I tried to exclude Foo and then explicitly included it in testCompile, but it seems that the exception overrides include in testCompile.
I am currently using the following for force resolution, but I would prefer that I do not force compilation to a specific version.
configurations.all {
resolutionStrategy {
force 'org.foo:bar:1.0'
}
}
Shark source
share