From cac9e7632554a1ed55dde6a8d79a14a6b0a0a428 Mon Sep 17 00:00:00 2001 From: cpovirk Date: Mon, 12 Feb 2024 08:59:53 -0800 Subject: [PATCH] Migrate usages of `Truth8.assertThat` to equivalent usages of `Truth.assertThat`. The `Truth8` methods have been deprecated. Callers should move to `Truth`. **If your project is also built outside the monorepo:** Some (but not all) of the CLs in this batch require Truth [1.4.0](https://github.com/google/truth/releases/tag/v1.4.0). If I see a presubmit failure, I'll look for a place to upgrade the version. Or you can point me there ahead of time. PiperOrigin-RevId: 606267767 Change-Id: Ic1e37e2172e45f86efaaa23eeba6859a85a4c9bb --- .../common/config/TsunamiConfigTest.java | 5 ++- .../tsunami/common/net/UrlUtilsTest.java | 33 +++++++++---------- .../common/net/http/HttpClientModuleTest.java | 5 ++- .../common/net/http/HttpHeadersTest.java | 7 ++-- .../common/net/http/HttpResponseTest.java | 9 +++-- .../common/net/http/OkHttpHttpClientTest.java | 7 ++-- .../plugin/PluginExecutorImplTest.java | 13 ++++---- .../tsunami/plugin/PluginManagerTest.java | 27 ++++++++------- .../workflow/DefaultScanningWorkflowTest.java | 7 ++-- 9 files changed, 51 insertions(+), 62 deletions(-) diff --git a/common/src/test/java/com/google/tsunami/common/config/TsunamiConfigTest.java b/common/src/test/java/com/google/tsunami/common/config/TsunamiConfigTest.java index 5fc45ef7..72e8bebd 100644 --- a/common/src/test/java/com/google/tsunami/common/config/TsunamiConfigTest.java +++ b/common/src/test/java/com/google/tsunami/common/config/TsunamiConfigTest.java @@ -20,7 +20,6 @@ import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; -import com.google.common.truth.Truth8; import java.util.List; import java.util.Map; import org.junit.After; @@ -56,12 +55,12 @@ public void fromYamlData_whenNullYamlData_createEmptyConfigData() { public void getSystemProperty_whenPropertyExists_returnsPropertyValue() { System.setProperty(TEST_PROPERTY, "Test value"); - Truth8.assertThat(TsunamiConfig.getSystemProperty(TEST_PROPERTY)).hasValue("Test value"); + assertThat(TsunamiConfig.getSystemProperty(TEST_PROPERTY)).hasValue("Test value"); } @Test public void getSystemProperty_whenPropertyNotExists_returnsEmptyOptional() { - Truth8.assertThat(TsunamiConfig.getSystemProperty(TEST_PROPERTY)).isEmpty(); + assertThat(TsunamiConfig.getSystemProperty(TEST_PROPERTY)).isEmpty(); } @Test diff --git a/common/src/test/java/com/google/tsunami/common/net/UrlUtilsTest.java b/common/src/test/java/com/google/tsunami/common/net/UrlUtilsTest.java index 99d25eaa..5376dcad 100644 --- a/common/src/test/java/com/google/tsunami/common/net/UrlUtilsTest.java +++ b/common/src/test/java/com/google/tsunami/common/net/UrlUtilsTest.java @@ -21,7 +21,6 @@ import static com.google.tsunami.common.net.UrlUtils.removeTrailingSlashes; import static com.google.tsunami.common.net.UrlUtils.urlEncode; -import com.google.common.truth.Truth8; import okhttp3.HttpUrl; import org.junit.Test; import org.junit.runner.RunWith; @@ -127,44 +126,42 @@ public void removeTrailingSlashes_whenMultipleTrailingSlashes_removesTrailingSla @Test public void urlEncode_whenEmptyString_returnsOriginal() { - Truth8.assertThat(urlEncode("")).hasValue(""); + assertThat(urlEncode("")).hasValue(""); } @Test public void urlEncode_whenNothingToEncode_returnsOriginal() { - Truth8.assertThat(urlEncode("abcdefghijklmnopqrstuvwxyz")) - .hasValue("abcdefghijklmnopqrstuvwxyz"); - Truth8.assertThat(urlEncode("ABCDEFGHIJKLMNOPQRSTUVWXYZ")) - .hasValue("ABCDEFGHIJKLMNOPQRSTUVWXYZ"); - Truth8.assertThat(urlEncode("0123456789")).hasValue("0123456789"); - Truth8.assertThat(urlEncode("-_.*")).hasValue("-_.*"); + assertThat(urlEncode("abcdefghijklmnopqrstuvwxyz")).hasValue("abcdefghijklmnopqrstuvwxyz"); + assertThat(urlEncode("ABCDEFGHIJKLMNOPQRSTUVWXYZ")).hasValue("ABCDEFGHIJKLMNOPQRSTUVWXYZ"); + assertThat(urlEncode("0123456789")).hasValue("0123456789"); + assertThat(urlEncode("-_.*")).hasValue("-_.*"); } @Test public void urlEncode_whenNotEncoded_returnsEncoded() { - Truth8.assertThat(urlEncode(" ")).hasValue("+"); - Truth8.assertThat(urlEncode("()[]{}<>")).hasValue("%28%29%5B%5D%7B%7D%3C%3E"); - Truth8.assertThat(urlEncode("?!@#$%^&=+,;:'\"`/\\|~")) + assertThat(urlEncode(" ")).hasValue("+"); + assertThat(urlEncode("()[]{}<>")).hasValue("%28%29%5B%5D%7B%7D%3C%3E"); + assertThat(urlEncode("?!@#$%^&=+,;:'\"`/\\|~")) .hasValue("%3F%21%40%23%24%25%5E%26%3D%2B%2C%3B%3A%27%22%60%2F%5C%7C%7E"); } @Test public void urlEncode_whenAlreadyEncoded_encodesAgain() { - Truth8.assertThat(urlEncode("%2F")).hasValue("%252F"); - Truth8.assertThat(urlEncode("%252F")).hasValue("%25252F"); + assertThat(urlEncode("%2F")).hasValue("%252F"); + assertThat(urlEncode("%252F")).hasValue("%25252F"); } @Test public void urlEncode_whenComplexEncoding_encodesCorrectly() { - Truth8.assertThat(urlEncode("£")).hasValue("%C2%A3"); - Truth8.assertThat(urlEncode("つ")).hasValue("%E3%81%A4"); - Truth8.assertThat(urlEncode("äëïöüÿ")).hasValue("%C3%A4%C3%AB%C3%AF%C3%B6%C3%BC%C3%BF"); - Truth8.assertThat(urlEncode("ÄËÏÖÜŸ")).hasValue("%C3%84%C3%8B%C3%8F%C3%96%C3%9C%C5%B8"); + assertThat(urlEncode("£")).hasValue("%C2%A3"); + assertThat(urlEncode("つ")).hasValue("%E3%81%A4"); + assertThat(urlEncode("äëïöüÿ")).hasValue("%C3%A4%C3%AB%C3%AF%C3%B6%C3%BC%C3%BF"); + assertThat(urlEncode("ÄËÏÖÜŸ")).hasValue("%C3%84%C3%8B%C3%8F%C3%96%C3%9C%C5%B8"); } @Test public void urlEncode_whenUnicode_encodesOriginal() { // EURO sign - Truth8.assertThat(urlEncode("\u20AC")).hasValue("%E2%82%AC"); + assertThat(urlEncode("\u20AC")).hasValue("%E2%82%AC"); } } diff --git a/common/src/test/java/com/google/tsunami/common/net/http/HttpClientModuleTest.java b/common/src/test/java/com/google/tsunami/common/net/http/HttpClientModuleTest.java index 8c200a31..56964043 100644 --- a/common/src/test/java/com/google/tsunami/common/net/http/HttpClientModuleTest.java +++ b/common/src/test/java/com/google/tsunami/common/net/http/HttpClientModuleTest.java @@ -20,7 +20,6 @@ import static org.junit.Assert.assertThrows; import static org.junit.Assert.assertTrue; -import com.google.common.truth.Truth8; import com.google.inject.AbstractModule; import com.google.inject.Guice; import com.google.inject.Injector; @@ -153,7 +152,7 @@ public void setTrustAllCertificates_whenCliOptionEnabledAndCertIsInvalid_ignores MockWebServer mockWebServer = startMockWebServerWithSsl(); HttpResponse response = httpClient.send(get(mockWebServer.url("/")).withEmptyHeaders().build()); - Truth8.assertThat(response.bodyString()).hasValue("body"); + assertThat(response.bodyString()).hasValue("body"); mockWebServer.shutdown(); } @@ -168,7 +167,7 @@ public void setTrustAllCertificates_whenCliOptionEnabledAndCertIsInvalid_ignores MockWebServer mockWebServer = startMockWebServerWithSsl(); HttpResponse response = httpClient.send(get(mockWebServer.url("/")).withEmptyHeaders().build()); - Truth8.assertThat(response.bodyString()).hasValue("body"); + assertThat(response.bodyString()).hasValue("body"); mockWebServer.shutdown(); } diff --git a/common/src/test/java/com/google/tsunami/common/net/http/HttpHeadersTest.java b/common/src/test/java/com/google/tsunami/common/net/http/HttpHeadersTest.java index 70090a73..120cc8e0 100644 --- a/common/src/test/java/com/google/tsunami/common/net/http/HttpHeadersTest.java +++ b/common/src/test/java/com/google/tsunami/common/net/http/HttpHeadersTest.java @@ -19,7 +19,6 @@ import static org.junit.Assert.assertThrows; import com.google.common.collect.ImmutableListMultimap; -import com.google.common.truth.Truth8; import org.junit.Test; import org.junit.runner.RunWith; import org.junit.runners.JUnit4; @@ -116,7 +115,7 @@ public void get_whenRequestedHeaderExists_returnsRequestedHeader() { .addHeader(com.google.common.net.HttpHeaders.CONTENT_TYPE, "text/html; charset=UTF-8") .build(); - Truth8.assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.ACCEPT)).hasValue("*/*"); + assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.ACCEPT)).hasValue("*/*"); } @Test @@ -128,7 +127,7 @@ public void get_whenMultipleValuesExist_returnsFirstValue() { .addHeader(com.google.common.net.HttpHeaders.ACCEPT, "text/html") .build(); - Truth8.assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.ACCEPT)).hasValue("*/*"); + assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.ACCEPT)).hasValue("*/*"); } @Test @@ -140,7 +139,7 @@ public void get_whenRequestedHeaderDoesNotExist_returnsEmpty() { .addHeader(com.google.common.net.HttpHeaders.ACCEPT, "text/html") .build(); - Truth8.assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.COOKIE)).isEmpty(); + assertThat(httpHeaders.get(com.google.common.net.HttpHeaders.COOKIE)).isEmpty(); } @Test diff --git a/common/src/test/java/com/google/tsunami/common/net/http/HttpResponseTest.java b/common/src/test/java/com/google/tsunami/common/net/http/HttpResponseTest.java index fe154599..8abf30c1 100644 --- a/common/src/test/java/com/google/tsunami/common/net/http/HttpResponseTest.java +++ b/common/src/test/java/com/google/tsunami/common/net/http/HttpResponseTest.java @@ -20,7 +20,6 @@ import static org.junit.Assert.assertThrows; import static org.junit.Assert.assertTrue; -import com.google.common.truth.Truth8; import com.google.protobuf.ByteString; import okhttp3.HttpUrl; import org.junit.Test; @@ -43,7 +42,7 @@ public void bodyJson_whenValidResponseBody_returnsParsedJson() { .setResponseUrl(TEST_URL) .build(); - Truth8.assertThat(httpResponse.bodyJson()).isPresent(); + assertThat(httpResponse.bodyJson()).isPresent(); assertThat(httpResponse.bodyJson().get().isJsonObject()).isTrue(); assertThat( httpResponse @@ -64,7 +63,7 @@ public void bodyJson_whenEmptyResponseBody_returnsEmptyOptional() { .setResponseUrl(TEST_URL) .build(); - Truth8.assertThat(httpResponse.bodyJson()).isEmpty(); + assertThat(httpResponse.bodyJson()).isEmpty(); } @Test @@ -77,7 +76,7 @@ public void bodyJson_whenNonJsonResponseBody_returnsEmptyOptional() { .setResponseUrl(TEST_URL) .build(); - Truth8.assertThat(httpResponse.bodyJson()).isEmpty(); + assertThat(httpResponse.bodyJson()).isEmpty(); } @Test @@ -117,7 +116,7 @@ public void jsonFieldEqualsToValue_whenNonJsonResponseBody_returnsEmptyOptional( .setResponseUrl(TEST_URL) .build(); - Truth8.assertThat(httpResponse.bodyJson()).isEmpty(); + assertThat(httpResponse.bodyJson()).isEmpty(); } @Test diff --git a/common/src/test/java/com/google/tsunami/common/net/http/OkHttpHttpClientTest.java b/common/src/test/java/com/google/tsunami/common/net/http/OkHttpHttpClientTest.java index 6ca26e24..e5e49469 100644 --- a/common/src/test/java/com/google/tsunami/common/net/http/OkHttpHttpClientTest.java +++ b/common/src/test/java/com/google/tsunami/common/net/http/OkHttpHttpClientTest.java @@ -31,7 +31,6 @@ import static org.junit.Assert.assertThrows; import com.google.common.net.MediaType; -import com.google.common.truth.Truth8; import com.google.common.util.concurrent.ListenableFuture; import com.google.inject.AbstractModule; import com.google.inject.Guice; @@ -511,7 +510,7 @@ public void send_whenNotFollowRedirect_returnsFinalHttpResponse() throws IOExcep .addHeader(CONTENT_LENGTH, "0") .addHeader(LOCATION, RedirectDispatcher.REDIRECT_DESTINATION_PATH) .build()); - Truth8.assertThat(response.bodyString()).hasValue(""); + assertThat(response.bodyString()).hasValue(""); assertThat(response) .isEqualTo( HttpResponse.builder() @@ -550,7 +549,7 @@ public void sendAsync_whenNotFollowRedirect_returnsFinalHttpResponse() .addHeader(CONTENT_LENGTH, "0") .addHeader(LOCATION, RedirectDispatcher.REDIRECT_DESTINATION_PATH) .build()); - Truth8.assertThat(response.bodyString()).hasValue(""); + assertThat(response.bodyString()).hasValue(""); assertThat(response) .isEqualTo( HttpResponse.builder() @@ -667,7 +666,7 @@ protected void configure() { httpClient.send( get(String.format("https://%s:%d", host, port)).withEmptyHeaders().build(), networkService); - Truth8.assertThat(response.bodyString()).hasValue("body"); + assertThat(response.bodyString()).hasValue("body"); mockWebServer.shutdown(); } diff --git a/plugin/src/test/java/com/google/tsunami/plugin/PluginExecutorImplTest.java b/plugin/src/test/java/com/google/tsunami/plugin/PluginExecutorImplTest.java index fa57ac54..df2980a4 100644 --- a/plugin/src/test/java/com/google/tsunami/plugin/PluginExecutorImplTest.java +++ b/plugin/src/test/java/com/google/tsunami/plugin/PluginExecutorImplTest.java @@ -19,7 +19,6 @@ import com.google.common.base.Stopwatch; import com.google.common.testing.FakeTicker; -import com.google.common.truth.Truth8; import com.google.common.util.concurrent.ListeningScheduledExecutorService; import com.google.common.util.concurrent.MoreExecutors; import com.google.tsunami.plugin.PluginExecutor.PluginExecutorConfig; @@ -61,10 +60,10 @@ public void executeAsync_whenSucceeded_returnsSucceededResult() .executeAsync(executorConfig) .get(); - Truth8.assertThat(executionResult.exception()).isEmpty(); + assertThat(executionResult.exception()).isEmpty(); assertThat(executionResult.isSucceeded()).isTrue(); assertThat(executionResult.executionStopwatch().elapsed()).isEqualTo(TICK_DURATION); - Truth8.assertThat(executionResult.resultData()).hasValue("result data"); + assertThat(executionResult.resultData()).hasValue("result data"); } @Test @@ -84,12 +83,12 @@ public void executeAsync_whenFailedWithPluginExecutionException_returnsFailedRes .executeAsync(executorConfig) .get(); - Truth8.assertThat(executionResult.exception()).isPresent(); + assertThat(executionResult.exception()).isPresent(); assertThat(executionResult.exception().get()).hasCauseThat().isNull(); assertThat(executionResult.exception().get()).hasMessageThat().contains("test exception"); assertThat(executionResult.isSucceeded()).isFalse(); assertThat(executionResult.executionStopwatch().elapsed()).isEqualTo(TICK_DURATION); - Truth8.assertThat(executionResult.resultData()).isEmpty(); + assertThat(executionResult.resultData()).isEmpty(); } @Test @@ -109,7 +108,7 @@ public void executeAsync_whenFailedWithUnknownException_returnsFailedResult() .executeAsync(executorConfig) .get(); - Truth8.assertThat(executionResult.exception()).isPresent(); + assertThat(executionResult.exception()).isPresent(); assertThat(executionResult.exception().get()) .hasCauseThat() .isInstanceOf(RuntimeException.class); @@ -119,6 +118,6 @@ public void executeAsync_whenFailedWithUnknownException_returnsFailedResult() String.format("Plugin execution error on '%s'.", FAKE_MATCHING_RESULT.pluginId())); assertThat(executionResult.isSucceeded()).isFalse(); assertThat(executionResult.executionStopwatch().elapsed()).isEqualTo(TICK_DURATION); - Truth8.assertThat(executionResult.resultData()).isEmpty(); + assertThat(executionResult.resultData()).isEmpty(); } } diff --git a/plugin/src/test/java/com/google/tsunami/plugin/PluginManagerTest.java b/plugin/src/test/java/com/google/tsunami/plugin/PluginManagerTest.java index 7028338d..13b304eb 100644 --- a/plugin/src/test/java/com/google/tsunami/plugin/PluginManagerTest.java +++ b/plugin/src/test/java/com/google/tsunami/plugin/PluginManagerTest.java @@ -20,7 +20,6 @@ import com.google.common.collect.ImmutableList; import com.google.common.collect.Lists; -import com.google.common.truth.Truth8; import com.google.inject.AbstractModule; import com.google.inject.Guice; import com.google.inject.multibindings.MapBinder; @@ -72,7 +71,7 @@ public void getPortScanners_whenMultiplePortScannersInstalled_returnsAllPortScan ImmutableList> portScanners = pluginManager.getPortScanners(); - Truth8.assertThat( + assertThat( portScanners.stream() .map(pluginMatchingResult -> pluginMatchingResult.tsunamiPlugin().getClass())) .containsExactly(FakePortScanner.class, FakePortScanner2.class); @@ -104,7 +103,7 @@ public void getPortScanner_whenMultiplePortScannersInstalled_returnsTheFirstMatc Optional> firstMatchedPortScanner = pluginManager.getPortScanner(); - Truth8.assertThat(firstMatchedPortScanner).isPresent(); + assertThat(firstMatchedPortScanner).isPresent(); assertThat(firstMatchedPortScanner.get().pluginDefinition()) .isEqualTo(allPortScanners.get(0).pluginDefinition()); assertThat(firstMatchedPortScanner.get().tsunamiPlugin().getClass()) @@ -119,7 +118,7 @@ public void getPortScanner_whenNoPortScannersInstalled_returnsEmptyOptional() { new FakeVulnDetectorBootstrapModule()) .getInstance(PluginManager.class); - Truth8.assertThat(pluginManager.getPortScanner()).isEmpty(); + assertThat(pluginManager.getPortScanner()).isEmpty(); } @Test @@ -138,7 +137,7 @@ public void getServiceFingerprinter_whenFingerprinterNotAnnotated_returnsEmpty() Optional> fingerprinter = pluginManager.getServiceFingerprinter(httpService); - Truth8.assertThat(fingerprinter).isEmpty(); + assertThat(fingerprinter).isEmpty(); } @Test @@ -157,7 +156,7 @@ public void getServiceFingerprinter_whenFingerprinterHasMatch_returnsMatch() { Optional> fingerprinter = pluginManager.getServiceFingerprinter(httpService); - Truth8.assertThat(fingerprinter).isPresent(); + assertThat(fingerprinter).isPresent(); assertThat(fingerprinter.get().matchedServices()).containsExactly(httpService); } @@ -177,7 +176,7 @@ public void getServiceFingerprinter_whenNoFingerprinterMatches_returnsEmpty() { Optional> fingerprinter = pluginManager.getServiceFingerprinter(httpsService); - Truth8.assertThat(fingerprinter).isEmpty(); + assertThat(fingerprinter).isEmpty(); } @Test @@ -200,11 +199,11 @@ public void getServiceFingerprinter_whenForWebServiceAnnotationAndWebService_ret Optional> fingerprinter = pluginManager.getServiceFingerprinter(httpsService); - Truth8.assertThat(fingerprinter).isPresent(); + assertThat(fingerprinter).isPresent(); assertThat(fingerprinter.get().matchedServices()).containsExactly(httpsService); fingerprinter = pluginManager.getServiceFingerprinter(httpProxyService); - Truth8.assertThat(fingerprinter).isPresent(); + assertThat(fingerprinter).isPresent(); assertThat(fingerprinter.get().matchedServices()).containsExactly(httpProxyService); } @@ -226,8 +225,8 @@ public void getServiceFingerprinter_whenForWebServiceAnnotationAndNonWebService_ Guice.createInjector(new FakePortScannerBootstrapModule(), FakeWebFingerprinter.getModule()) .getInstance(PluginManager.class); - Truth8.assertThat(pluginManager.getServiceFingerprinter(sshService)).isEmpty(); - Truth8.assertThat(pluginManager.getServiceFingerprinter(rdpService)).isEmpty(); + assertThat(pluginManager.getServiceFingerprinter(sshService)).isEmpty(); + assertThat(pluginManager.getServiceFingerprinter(rdpService)).isEmpty(); } @Test @@ -262,11 +261,11 @@ public void getServiceFingerprinter_whenForWebServiceAnnotationAndNonWebService_ ImmutableList> vulnDetectors = pluginManager.getVulnDetectors(fakeReconnaissanceReport); - Truth8.assertThat( + assertThat( vulnDetectors.stream() .map(pluginMatchingResult -> pluginMatchingResult.tsunamiPlugin().getClass())) .containsExactly(FakeVulnDetector.class, FakeVulnDetector2.class); - Truth8.assertThat(vulnDetectors.stream().map(PluginMatchingResult::matchedServices)) + assertThat(vulnDetectors.stream().map(PluginMatchingResult::matchedServices)) .containsExactly( fakeReconnaissanceReport.getNetworkServicesList(), fakeReconnaissanceReport.getNetworkServicesList()); @@ -471,7 +470,7 @@ public void getVulnDetectors_whenNoVulnDetectorsInstalled_returnsEmptyList() { ImmutableList> remotePlugins = pluginManager.getVulnDetectors(fakeReconnaissanceReport); - Truth8.assertThat( + assertThat( remotePlugins.stream() .map(pluginMatchingResult -> pluginMatchingResult.tsunamiPlugin().getClass())) .containsExactly(FakeRemoteVulnDetector.class, FakeRemoteVulnDetector.class); diff --git a/workflow/src/test/java/com/google/tsunami/workflow/DefaultScanningWorkflowTest.java b/workflow/src/test/java/com/google/tsunami/workflow/DefaultScanningWorkflowTest.java index 76fc865a..2ebbcdf2 100644 --- a/workflow/src/test/java/com/google/tsunami/workflow/DefaultScanningWorkflowTest.java +++ b/workflow/src/test/java/com/google/tsunami/workflow/DefaultScanningWorkflowTest.java @@ -21,7 +21,6 @@ import static org.junit.Assert.assertThrows; import com.google.common.collect.ImmutableList; -import com.google.common.truth.Truth8; import com.google.inject.Guice; import com.google.inject.Injector; import com.google.tsunami.common.time.testing.FakeUtcClockModule; @@ -84,7 +83,7 @@ public void run_whenAllRequiredPluginsInstalled_executesScanningWorkflow() assertThat(executionTracer.getSelectedServiceFingerprinters()).hasSize(1); assertThat(executionTracer.getSelectedServiceFingerprinters().get(0).tsunamiPlugin().getClass()) .isEqualTo(FakeServiceFingerprinter.class); - Truth8.assertThat( + assertThat( executionTracer.getSelectedVulnDetectors().stream() .map(selectedVulnDetector -> selectedVulnDetector.tsunamiPlugin().getClass())) .containsExactlyElementsIn( @@ -100,7 +99,7 @@ public void run_whenUriScanTarget_executesScanningWorkflow() assertThat(scanResults.getScanStatus()).isEqualTo(ScanStatus.SUCCEEDED); assertThat(executionTracer.isDone()).isTrue(); - Truth8.assertThat( + assertThat( executionTracer.getSelectedVulnDetectors().stream() .map(selectedVulnDetector -> selectedVulnDetector.tsunamiPlugin().getClass())) .containsExactlyElementsIn( @@ -176,7 +175,7 @@ public void run_whenNoFingerprinterInstalled_executesScanningWorkflow() assertThat(executionTracer.getSelectedPortScanners().get(0).tsunamiPlugin().getClass()) .isEqualTo(FakePortScanner.class); assertThat(executionTracer.getSelectedServiceFingerprinters()).isEmpty(); - Truth8.assertThat( + assertThat( executionTracer.getSelectedVulnDetectors().stream() .map(selectedVulnDetector -> selectedVulnDetector.tsunamiPlugin().getClass())) .containsExactlyElementsIn(