diff options
author | Jacek <52388493+jacek-poreda-sonarsource@users.noreply.github.com> | 2019-09-30 15:43:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-30 15:43:00 +0200 |
commit | 70da1689e80a7afd3f107e9ae9d3deac94f6c9b9 (patch) | |
tree | 5d3c57d848ef324ba862f67002a3f951c28d49e2 /src/test/java/org/sonarsource/scanner | |
parent | 465dd079c79d1f2297a430d3b2cdd58513e8d61d (diff) | |
download | sonar-scanner-cli-70da1689e80a7afd3f107e9ae9d3deac94f6c9b9.tar.gz sonar-scanner-cli-70da1689e80a7afd3f107e9ae9d3deac94f6c9b9.zip |
Update travis utils version for appveyor (#75)
Diffstat (limited to 'src/test/java/org/sonarsource/scanner')
-rw-r--r-- | src/test/java/org/sonarsource/scanner/cli/ConfTest.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/test/java/org/sonarsource/scanner/cli/ConfTest.java b/src/test/java/org/sonarsource/scanner/cli/ConfTest.java index 1dbbbec..a5c8b5f 100644 --- a/src/test/java/org/sonarsource/scanner/cli/ConfTest.java +++ b/src/test/java/org/sonarsource/scanner/cli/ConfTest.java @@ -33,6 +33,7 @@ import org.junit.Rule; import org.junit.Test; import org.junit.rules.ExpectedException; import org.junit.rules.TemporaryFolder; +import org.sonarsource.scanner.api.internal.shaded.minimaljson.Json; import static org.assertj.core.api.Assertions.assertThat; import static org.junit.Assume.assumeTrue; @@ -326,7 +327,11 @@ public class ConfTest { Properties properties = conf.properties(); assertThat(properties.get("sonar.prop")).isEqualTo("default"); - env.put("SONARQUBE_SCANNER_PARAMS", "{\"project.settings\" : \"" + home.resolve("conf/sq-project.properties").toAbsolutePath().toString() + "\"}"); + String jsonString = Json.object() + .add("project.settings", home.resolve("conf/sq-project.properties").toAbsolutePath().toString()) + .toString(); + + env.put("SONARQUBE_SCANNER_PARAMS", jsonString); properties = conf.properties(); assertThat(properties.get("sonar.prop")).isEqualTo("expected"); |