From 50c1d9b5781d68f18fd37a555d43b2688e368d26 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Amaury=20Lev=C3=A9?= Date: Thu, 26 Apr 2018 11:11:04 +0200 Subject: [PATCH] Add more unit tests regarding the --embedded switch (#49) --- src/test/java/org/sonarsource/scanner/cli/CliTest.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/test/java/org/sonarsource/scanner/cli/CliTest.java b/src/test/java/org/sonarsource/scanner/cli/CliTest.java index ad9d942..82fba5d 100644 --- a/src/test/java/org/sonarsource/scanner/cli/CliTest.java +++ b/src/test/java/org/sonarsource/scanner/cli/CliTest.java @@ -36,6 +36,7 @@ public class CliTest { assertThat(cli.properties()).isNotEmpty(); assertThat(cli.isDebugEnabled()).isFalse(); assertThat(cli.isDisplayVersionOnly()).isFalse(); + assertThat(cli.isEmbedded()).isFalse(); } @Test @@ -143,4 +144,10 @@ public class CliTest { verify(logs).info("usage: sonar-scanner [options]"); verify(exit).exit(Exit.ERROR); } + + @Test + public void should_enable_embedded_mode() { + cli.parse(new String[] {"--embedded"}); + assertThat(cli.isEmbedded()).isTrue(); + } } -- 2.39.5