Skip to content

guava:32.1.1-jre causes issues with mockito-core:3.x #6654

Closed
@amitlpande

Description

@amitlpande

Hello,

In our project, we use mockito 3.x (3.8.0) for unit testing.
When we attempted to upgrade guava-jre to 32.1.1, we're running into odd issues.

Below is build.gradle file snip:

dependencies {

implementation 'org.mockito:mockito-core:3.8.0' // this is done just for testing ..
implementation 'com.google.guava:guava:32.1.1-jre'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.8.1'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.8.1'

}

When code is compiled - running into this:

Task :compileJava FAILED
/tmp/mytestprojects/test/src/main/java/org/example/Main.java:8: error: cannot find symbol
org.mockito.Matchers.matches("abc");
^
symbol: class Matchers
location: package org.mockito
1 error

FAILURE: Build failed with an exception.

However, the code just compiles fine when we switch to 32.0.1-jre.

Appreciate your help in triaging this.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions