Skip to content

Commit

Permalink
Update test dependencies
Browse files Browse the repository at this point in the history
This updates JUnit, TestContainers, Lombok, and Mockito together as it
wasn't possible to only update TestContainers alone since it also
depends on JUnit, see PR JanusGraph#2972.
The same applies to Mockito.

These changes were necessary to update Mockito to v4:

Import of `org.mockito.Matchers` needed to be changed to
`org.mockito.ArgumentMatchers`. `Matchers` was already only an alias
for `ArgumentMatchers` before as described in the release notes:
https://github.com/mockito/mockito/releases/tag/v4.0.0

`any()` is the replacement for `anyObject()`:
mockito/mockito#1931

Signed-off-by: Florian Hockmann <fh@florian-hockmann.de>
  • Loading branch information
FlorianHockmann committed Jun 22, 2022
1 parent c4a0a27 commit 0599c08
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
Expand Up @@ -63,7 +63,6 @@
import static org.mockito.Mockito.any;
import static org.mockito.Mockito.anyBoolean;
import static org.mockito.Mockito.anyInt;
import static org.mockito.Mockito.anyObject;
import static org.mockito.Mockito.anyString;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.eq;
Expand Down Expand Up @@ -306,7 +305,7 @@ private CredentialsProvider basicAuthTestBase(final Map<String, String> extraCon
);

final HttpAsyncClientBuilder hacb = mock(HttpAsyncClientBuilder.class);
doReturn(hacb).when(hacb).setDefaultCredentialsProvider(anyObject());
doReturn(hacb).when(hacb).setDefaultCredentialsProvider(any());
hccc.customizeHttpClient(hacb);

final ArgumentCaptor<BasicCredentialsProvider> cpCaptor = ArgumentCaptor.forClass(BasicCredentialsProvider.class);
Expand Down
Expand Up @@ -39,7 +39,7 @@
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertTrue;
import static org.mockito.Matchers.eq;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;

Expand Down
10 changes: 5 additions & 5 deletions pom.xml
Expand Up @@ -57,9 +57,9 @@
<properties>
<titan.compatible-versions>1.0.0,1.1.0-SNAPSHOT</titan.compatible-versions>
<tinkerpop.version>3.5.3</tinkerpop.version>
<junit-platform.version>1.8.1</junit-platform.version>
<junit.version>5.8.1</junit.version>
<mockito.version>3.12.4</mockito.version>
<junit-platform.version>1.8.2</junit-platform.version>
<junit.version>5.8.2</junit.version>
<mockito.version>4.6.1</mockito.version>
<jamm.version>0.3.0</jamm.version>
<metrics.version>4.1.18</metrics.version>
<slf4j.version>1.7.35</slf4j.version>
Expand Down Expand Up @@ -108,7 +108,7 @@
<cassandra.version.sha256>bbe772956c841158e3228c3b6c8fc38cece6bceeface695473c59c0573039bf1</cassandra.version.sha256>
<cassandra-driver.version>4.14.1</cassandra-driver.version>
<scylladb.version>4.4.0</scylladb.version>
<testcontainers.version>1.16.2</testcontainers.version>
<testcontainers.version>1.17.2</testcontainers.version>
<easymock.version>4.3</easymock.version>
<protobuf.version>3.19.2</protobuf.version>
<grpc.version>1.42.1</grpc.version>
Expand Down Expand Up @@ -1139,7 +1139,7 @@
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.18</version>
<version>1.18.24</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
Expand Down

1 comment on commit 0599c08

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: 0599c08 Previous: a5f549f Ratio
org.janusgraph.MgmtOlapJobBenchmark.runRemoveIndex 115.09829334355182 ms/op 114.05950851272728 ms/op 1.01
org.janusgraph.JanusGraphSpeedBenchmark.basicAddAndDelete 12780.079831023957 ms/op 13461.300170678296 ms/op 0.95
org.janusgraph.GraphCentricQueryBenchmark.getVertices 2262.2839215552267 ms/op 2046.9050105544957 ms/op 1.11
org.janusgraph.MgmtOlapJobBenchmark.runReindex 356.1024953066667 ms/op 349.0224117504762 ms/op 1.02
org.janusgraph.JanusGraphSpeedBenchmark.basicCount 312.11224293292554 ms/op 288.6154362374195 ms/op 1.08

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.