aboutsummaryrefslogtreecommitdiffstats
path: root/src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java
diff options
context:
space:
mode:
authorJulien HENRY <julien.henry@sonarsource.com>2024-05-03 11:40:31 +0200
committerJulien HENRY <julien.henry@sonarsource.com>2024-05-03 14:48:44 +0200
commit43be745547fcc827761a172136c3f3e9834f5544 (patch)
treeac0055706ac3a5a0df5af5512abdd1a6694157f7 /src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java
parente7fc5ea5667ce260ad48d5603c262614bbed8222 (diff)
downloadsonar-scanner-cli-43be745547fcc827761a172136c3f3e9834f5544.tar.gz
sonar-scanner-cli-43be745547fcc827761a172136c3f3e9834f5544.zip
Update tests to JUnit 5
Diffstat (limited to 'src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java')
-rw-r--r--src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java b/src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java
index f3ae408..cfaca6f 100644
--- a/src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java
+++ b/src/test/java/org/sonarsource/scanner/cli/ScannerEngineBootstrapperFactoryTest.java
@@ -20,7 +20,7 @@
package org.sonarsource.scanner.cli;
import java.util.Properties;
-import org.junit.Test;
+import org.junit.jupiter.api.Test;
import org.sonarsource.scanner.lib.ScannerEngineBootstrapper;
import static org.assertj.core.api.Assertions.assertThat;
@@ -33,14 +33,14 @@ import static org.mockito.Mockito.spy;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
-public class ScannerEngineBootstrapperFactoryTest {
+class ScannerEngineBootstrapperFactoryTest {
private final Properties props = new Properties();
private final Logs logs = mock(Logs.class);
- private ScannerEngineBootstrapperFactory underTest = new ScannerEngineBootstrapperFactory(logs);
+ private final ScannerEngineBootstrapperFactory underTest = new ScannerEngineBootstrapperFactory(logs);
@Test
- public void should_create_engine_bootstrapper_and_pass_app_and_properties() {
+ void should_create_engine_bootstrapper_and_pass_app_and_properties() {
props.setProperty("foo", "bar");
var spy = spy(underTest);
var mockedBootstrapper = mock(ScannerEngineBootstrapper.class);
@@ -55,7 +55,7 @@ public class ScannerEngineBootstrapperFactoryTest {
}
@Test
- public void should_create_engine_bootstrapper_with_app_from_argument() {
+ void should_create_engine_bootstrapper_with_app_from_argument() {
var spy = spy(underTest);
var mockedBootstrapper = mock(ScannerEngineBootstrapper.class);
when(mockedBootstrapper.addBootstrapProperties(any())).thenReturn(mockedBootstrapper);
@@ -68,7 +68,7 @@ public class ScannerEngineBootstrapperFactoryTest {
}
@Test
- public void if_from_argument_is_not_regex_compliant_revert_to_default_scanner_name() {
+ void if_from_argument_is_not_regex_compliant_revert_to_default_scanner_name() {
var spy = spy(underTest);
var mockedBootstrapper = mock(ScannerEngineBootstrapper.class);
when(mockedBootstrapper.addBootstrapProperties(any())).thenReturn(mockedBootstrapper);