awslabs/eventbridge-kafka-connector

Tests fail with `Mockito cannot mock this class`

Opened this issue · 0 comments

Describe the bug

Running mvn clean package -Drevision=$(git describe --tags --always) can fail with:

[ERROR]   EventBridgeWriterTest.usesGlobalEndpointId » Mockito
Mockito cannot mock this class: interface software.amazon.awssdk.services.eventbridge.EventBridgeAsyncClient.

If you're not sure why you're getting this error, please open an issue on GitHub.

To Reproduce

Use OpenJDK 21 and run tests/compile the project.

Expected behavior

No error.

Environment:

OpenJDK 21

Additional context

Update CONTRIBUTING docs with instructions how to specify the correct JDK e.g., export JAVA_HOME=~/Library/Java/JavaVirtualMachines/openjdk-20.0.1/Contents/Home