1717package org .sonar .python .it ;
1818
1919import com .sonar .orchestrator .build .SonarScanner ;
20+ import com .sonar .orchestrator .version .Version ;
21+ import com .sonar .orchestrator .build .SonarScannerInstaller ;
22+ import com .sonar .orchestrator .config .Configuration ;
2023import com .sonar .orchestrator .junit5 .OrchestratorExtension ;
2124import com .sonar .orchestrator .locator .FileLocation ;
2225import java .io .File ;
2629import org .junit .jupiter .api .BeforeAll ;
2730import org .junit .jupiter .api .Test ;
2831import org .junit .jupiter .api .extension .RegisterExtension ;
32+ import org .junit .jupiter .api .parallel .Execution ;
33+ import org .junit .jupiter .api .parallel .ExecutionMode ;
2934import org .sonarsource .analyzer .commons .ProfileGenerator ;
3035
3136import static java .nio .charset .StandardCharsets .UTF_8 ;
3237import static org .assertj .core .api .Assertions .assertThat ;
3338import static org .sonar .python .it .RulingHelper .getOrchestrator ;
3439
35- // Ruling test for bug rules, to ensure they are properly tested without slowing down the CI
40+ @ Execution ( ExecutionMode . CONCURRENT )
3641class PythonRulingTest {
3742
43+
3844 @ RegisterExtension
3945 public static final OrchestratorExtension ORCHESTRATOR = getOrchestrator ();
46+ public static final Configuration CONFIGURATION = ORCHESTRATOR .getConfiguration ();
4047
4148 private static final String PROFILE_NAME = "rules" ;
4249
@@ -52,6 +59,11 @@ static void prepare_quality_profile() {
5259 ORCHESTRATOR .getServer ().restoreProfile (FileLocation .of (iPythonProfileFile ));
5360 }
5461
62+ @ BeforeAll
63+ static void install_sonar_scanner () {
64+ new SonarScannerInstaller (CONFIGURATION .locators ()).install (Version .create (SonarScanner .DEFAULT_SCANNER_VERSION ), CONFIGURATION .fileSystem ().workspace ());
65+ }
66+
5567 @ Test
5668 void test_airflow () throws IOException {
5769 SonarScanner build = buildWithCommonProperties ("airflow" );
0 commit comments