From 2d20c0f3f27356ad1f9aa430f3e5925c50756cfc Mon Sep 17 00:00:00 2001 From: Julien HENRY Date: Fri, 10 Jun 2016 09:45:15 +0200 Subject: SONAR-7751, SONAR-7756 SonarLint API --- .../sonar-xoo-plugin/src/test/java/org/sonar/xoo/XooPluginTest.java | 6 +++--- .../src/test/java/org/sonar/xoo/rule/OneIssuePerLineSensorTest.java | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'plugins/sonar-xoo-plugin') diff --git a/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/XooPluginTest.java b/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/XooPluginTest.java index 8c83a20bd32..138ba56fb5b 100644 --- a/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/XooPluginTest.java +++ b/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/XooPluginTest.java @@ -25,17 +25,17 @@ import org.sonar.api.utils.Version; import org.sonar.xoo.lang.CpdTokenizerSensor; import static org.assertj.core.api.Assertions.assertThat; -import static org.sonar.api.SonarQubeVersion.V5_5; +import static org.sonar.api.RuntimeApiVersion.V5_5; public class XooPluginTest { @Test public void provide_extensions_for_5_5() { - Plugin.Context context = new Plugin.Context(V5_5); + Plugin.Context context = new Plugin.Context(V5_5, false); new XooPlugin().define(context); assertThat(context.getExtensions()).hasSize(40).contains(CpdTokenizerSensor.class); - context = new Plugin.Context(Version.parse("5.4")); + context = new Plugin.Context(Version.parse("5.4"), false); new XooPlugin().define(context); assertThat(context.getExtensions()).hasSize(39).doesNotContain(CpdTokenizerSensor.class); } diff --git a/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/rule/OneIssuePerLineSensorTest.java b/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/rule/OneIssuePerLineSensorTest.java index f182004de3e..091c20b42f3 100644 --- a/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/rule/OneIssuePerLineSensorTest.java +++ b/plugins/sonar-xoo-plugin/src/test/java/org/sonar/xoo/rule/OneIssuePerLineSensorTest.java @@ -104,7 +104,7 @@ public class OneIssuePerLineSensorTest { SensorContextTester context = SensorContextTester.create(temp.newFolder()); context.fileSystem().add(inputFile); context.settings().setProperty(OneIssuePerLineSensor.EFFORT_TO_FIX_PROPERTY, "1.2"); - context.setSonarQubeVersion(Version.parse("5.4")); + context.setRuntime(Version.parse("5.4"), false); sensor.execute(context); -- cgit v1.2.3