diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml
index 1871caf072..bd769c3733 100644
--- a/.github/workflows/codeql-analysis.yml
+++ b/.github/workflows/codeql-analysis.yml
@@ -13,10 +13,10 @@ name: "CodeQL"
on:
push:
- branches: [ master ]
+ branches: [ SQ-10 ]
pull_request:
# The branches below must be a subset of the branches above
- branches: [ master ]
+ branches: [ SQ-10 ]
schedule:
- cron: '34 6 * * 4'
@@ -32,15 +32,26 @@ jobs:
strategy:
fail-fast: false
matrix:
+ java: [ '17' ]
+ distribution: [ 'temurin' ]
language: [ 'java', 'python' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
# Learn more:
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
steps:
+ # Checkout repository
- name: Checkout repository
uses: actions/checkout@v3
+ # setup Java
+ - name: Set up JDK Java ${{ matrix.java }} | ${{ matrix.distribution }} | ${{ matrix.os }}
+ uses: actions/setup-java@v3
+ with:
+ java-version: ${{ matrix.java }}
+ distribution: ${{ matrix.distribution }}
+ cache: maven
+
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
diff --git a/.github/workflows/cxx-ci.yml b/.github/workflows/cxx-ci.yml
index 2b619077d1..e1495da60d 100644
--- a/.github/workflows/cxx-ci.yml
+++ b/.github/workflows/cxx-ci.yml
@@ -6,9 +6,9 @@ name: cxx plugin CI
on:
push:
- branches: [ master ]
+ branches: [ SQ-10 ]
pull_request:
- branches: [ master ]
+ branches: [ SQ-10 ]
defaults:
run:
@@ -64,14 +64,14 @@ jobs:
# -----------------------------------------------------------------------------------------------------------
# Going through the Maven cycles 'validate', 'compile', 'test', 'package' in all combinations to be supported
- # The result of 'package' is uploaded as artifact for Ubuntu Linux Java 11 Temurin
+ # The result of 'package' is uploaded as artifact for Ubuntu Linux Java 17 Temurin
# -----------------------------------------------------------------------------------------------------------
build-linux:
strategy:
matrix:
os: [ubuntu-latest]
- java: [ '11' ]
+ java: [ '17' ]
distribution: [ 'temurin' ]
runs-on: ${{ matrix.os }}
@@ -134,10 +134,10 @@ jobs:
- name: Build and test with Maven
run: mvn -B -e -V verify --file pom.xml
- # create artifacts from Linux, Java 11 Temurin
+ # create artifacts from Linux, Java 17 Temurin
#
- name: Collect JAR files
- if: matrix.os == 'ubuntu-latest' && matrix.java == '11' && matrix.distribution == 'temurin'
+ if: matrix.os == 'ubuntu-latest' && matrix.java == '17' && matrix.distribution == 'temurin'
run: |
mkdir staging
cp sonar-cxx-plugin/target/*.jar staging
@@ -157,14 +157,14 @@ jobs:
# -----------------------------------------------------------------------------------------------------------
# Going through the Maven cycles 'validate', 'compile', 'test', 'package' in all combinations to be supported
- # The result of 'package' is uploaded as artifact for Ubuntu Linux Java 11 Temurin
+ # The result of 'package' is uploaded as artifact for Ubuntu Linux Java 17 Temurin
# -----------------------------------------------------------------------------------------------------------
build-windows:
strategy:
matrix:
os: [windows-latest]
- java: [ '11' ]
+ java: [ '17' ]
distribution: [ 'temurin' ]
runs-on: ${{ matrix.os }}
@@ -306,15 +306,10 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
- java: [ '11', '17' ]
+ java: [ '17' ]
distribution: [ 'temurin' ]
- sonarqube: [ '8.9.10.61524', '9.9.1.69595' ]
- sonarscanner: [ '4.8.0.2856' ]
- exclude:
- - sonarqube: '8.9.10.61524'
- java: '17'
- - sonarqube: '9.9.1.69595'
- java: '11'
+ sonarqube: [ '9.9.1.69595', '10.3.0.82913' ]
+ sonarscanner: [ '5.0.1.3006' ]
runs-on: ${{ matrix.os }}
needs: [build-linux, verify-rules]
@@ -452,15 +447,10 @@ jobs:
strategy:
matrix:
os: [windows-latest]
- java: [ '11', '17' ]
+ java: [ '17' ]
distribution: [ 'temurin' ]
- sonarqube: [ '8.9.10.61524', '9.9.1.69595' ]
- sonarscanner: [ '4.8.0.2856' ]
- exclude:
- - sonarqube: '8.9.10.61524'
- java: '17'
- - sonarqube: '9.9.1.69595'
- java: '11'
+ sonarqube: [ '9.9.1.69595', '10.3.0.82913' ]
+ sonarscanner: [ '5.0.1.3006' ]
runs-on: ${{ matrix.os }}
# needs build-linux because of JAR artifacts
diff --git a/cxx-sensors/pom.xml b/cxx-sensors/pom.xml
index 7aeb308b87..9b156fcfec 100644
--- a/cxx-sensors/pom.xml
+++ b/cxx-sensors/pom.xml
@@ -36,11 +36,21 @@
sonar-plugin-api
provided
+
+ org.sonarsource.api.plugin
+ sonar-plugin-api-test-fixtures
+ provided
+
org.sonarsource.sonarqube
sonar-plugin-api-impl
test
+
+ org.slf4j
+ slf4j-api
+ provided
+
com.google.code.findbugs
jsr305
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/postjobs/FinalReportTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/postjobs/FinalReportTest.java
index 28ce9f972d..05dfb2f97b 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/postjobs/FinalReportTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/postjobs/FinalReportTest.java
@@ -36,8 +36,8 @@
import org.sonar.api.batch.fs.internal.TestInputFileBuilder;
import org.sonar.api.batch.postjob.PostJobContext;
import org.sonar.api.batch.sensor.internal.SensorContextTester;
-import org.sonar.api.utils.log.LogTesterJUnit5;
-import org.sonar.api.utils.log.LoggerLevel;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
+import org.slf4j.event.Level;
import org.sonar.cxx.CxxAstScanner;
import org.sonar.cxx.preprocessor.CxxPreprocessor;
import org.sonar.cxx.visitors.CxxParseErrorLoggerVisitor;
@@ -68,7 +68,7 @@ void finalReportTest() throws IOException {
var postjob = new FinalReport();
postjob.execute(postJobContext);
- var log = logTester.logs(LoggerLevel.WARN);
+ var log = logTester.logs(Level.WARN);
assertThat(log).hasSize(2);
assertThat(log.get(0)).contains("include directive error(s)");
assertThat(log.get(1)).contains("syntax error(s) detected");
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/prejobs/XlstSensorTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/prejobs/XlstSensorTest.java
index 6add6469a6..3d5c9bfb95 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/prejobs/XlstSensorTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/prejobs/XlstSensorTest.java
@@ -29,8 +29,8 @@
import org.sonar.api.batch.fs.FileSystem;
import org.sonar.api.batch.sensor.internal.SensorContextTester;
import org.sonar.api.config.internal.MapSettings;
-import org.sonar.api.utils.log.LogTesterJUnit5;
-import org.sonar.api.utils.log.LoggerLevel;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
+import org.slf4j.event.Level;
import org.sonar.cxx.sensors.utils.CxxReportSensor;
import org.sonar.cxx.sensors.utils.TestUtils;
@@ -60,9 +60,9 @@ void noLoggingIfNotUsed() {
logTester.clear();
sensor.execute(context);
- assertThat(logTester.logs(LoggerLevel.ERROR)).isEmpty();
- assertThat(logTester.logs(LoggerLevel.WARN)).isEmpty();
- assertThat(logTester.logs(LoggerLevel.INFO)).isEmpty();
+ assertThat(logTester.logs(Level.ERROR)).isEmpty();
+ assertThat(logTester.logs(Level.WARN)).isEmpty();
+ assertThat(logTester.logs(Level.INFO)).isEmpty();
}
@Test
@@ -108,7 +108,7 @@ void shouldCreateMissingStylesheetMessage() {
logTester.clear();
sensor.execute(context);
- List log = logTester.logs(LoggerLevel.ERROR);
+ List log = logTester.logs(Level.ERROR);
assertThat(log).contains("XLST: 'sonar.cxx.xslt.1.stylesheet' value is not defined.");
}
@@ -124,7 +124,7 @@ void shouldCreateEmptyInputsMessage() {
logTester.clear();
sensor.execute(context);
- List log = logTester.logs(LoggerLevel.ERROR);
+ List log = logTester.logs(Level.ERROR);
assertThat(log).contains("XLST: 'sonar.cxx.xslt.1.inputs' value is not defined.");
}
@@ -141,7 +141,7 @@ void shouldCreateEmptyOutputsMessage() {
logTester.clear();
sensor.execute(context);
- List log = logTester.logs(LoggerLevel.ERROR);
+ List log = logTester.logs(Level.ERROR);
assertThat(log).contains("XLST: 'sonar.cxx.xslt.1.outputs' value is not defined.");
}
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/compiler/CxxCompilerSensorTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/compiler/CxxCompilerSensorTest.java
index 3e36e22382..53351548d4 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/compiler/CxxCompilerSensorTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/compiler/CxxCompilerSensorTest.java
@@ -30,7 +30,7 @@
import org.sonar.api.batch.sensor.SensorDescriptor;
import org.sonar.api.batch.sensor.internal.SensorContextTester;
import org.sonar.api.config.internal.MapSettings;
-import org.sonar.api.utils.log.LogTesterJUnit5;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
import org.sonar.cxx.sensors.utils.CxxReportSensor;
import org.sonar.cxx.sensors.utils.TestUtils;
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/coverage/CxxCoberturaSensorTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/coverage/CxxCoberturaSensorTest.java
index 1d98173779..19a8ed5d2d 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/coverage/CxxCoberturaSensorTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/coverage/CxxCoberturaSensorTest.java
@@ -35,7 +35,7 @@
import org.sonar.api.batch.sensor.internal.SensorContextTester;
import org.sonar.api.config.internal.MapSettings;
import org.sonar.api.utils.PathUtils;
-import org.sonar.api.utils.log.LogTesterJUnit5;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
import org.sonar.cxx.sensors.coverage.cobertura.CoberturaParser;
import org.sonar.cxx.sensors.coverage.cobertura.CxxCoverageCoberturaSensor;
import org.sonar.cxx.sensors.utils.CxxReportSensor;
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/other/CxxOtherSensorTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/other/CxxOtherSensorTest.java
index a1fd66bcaa..5bbefc795b 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/other/CxxOtherSensorTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/other/CxxOtherSensorTest.java
@@ -29,7 +29,7 @@
import org.sonar.api.batch.sensor.internal.DefaultSensorDescriptor;
import org.sonar.api.batch.sensor.internal.SensorContextTester;
import org.sonar.api.config.internal.MapSettings;
-import org.sonar.api.utils.log.LogTesterJUnit5;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
import org.sonar.cxx.sensors.utils.CxxReportSensor;
import org.sonar.cxx.sensors.utils.TestUtils;
diff --git a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/tests/dotnet/NUnitTestResultsFileParserTest.java b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/tests/dotnet/NUnitTestResultsFileParserTest.java
index 88f349fa4c..3792664442 100644
--- a/cxx-sensors/src/test/java/org/sonar/cxx/sensors/tests/dotnet/NUnitTestResultsFileParserTest.java
+++ b/cxx-sensors/src/test/java/org/sonar/cxx/sensors/tests/dotnet/NUnitTestResultsFileParserTest.java
@@ -28,8 +28,8 @@
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.RegisterExtension;
import static org.mockito.Mockito.mock;
-import org.sonar.api.utils.log.LogTesterJUnit5;
-import org.sonar.api.utils.log.LoggerLevel;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
+import org.slf4j.event.Level;
class NUnitTestResultsFileParserTest {
@@ -96,7 +96,7 @@ void empty() {
var results = new UnitTestResults();
new NUnitTestResultsFileParser().accept(new File(REPORT_PATH + "empty.xml"), results);
- assertThat(logTester.logs(LoggerLevel.WARN))
+ assertThat(logTester.logs(Level.WARN))
.contains("One of the assemblies contains no test result, please make sure this is expected.");
assertThat(results.tests()).isZero();
assertThat(results.passedPercentage()).isZero();
diff --git a/cxx-squid/pom.xml b/cxx-squid/pom.xml
index 78ab7901d2..b8a8576fa9 100644
--- a/cxx-squid/pom.xml
+++ b/cxx-squid/pom.xml
@@ -41,11 +41,21 @@
sonar-plugin-api
provided
+
+ org.sonarsource.api.plugin
+ sonar-plugin-api-test-fixtures
+ provided
+
org.sonarsource.sonarqube
sonar-plugin-api-impl
test
+
+ org.slf4j
+ slf4j-api
+ provided
+
com.google.code.findbugs
jsr305
diff --git a/cxx-squid/src/test/java/org/sonar/cxx/AggregateMeasureComputerTest.java b/cxx-squid/src/test/java/org/sonar/cxx/AggregateMeasureComputerTest.java
index da91438bde..b18d8291b1 100644
--- a/cxx-squid/src/test/java/org/sonar/cxx/AggregateMeasureComputerTest.java
+++ b/cxx-squid/src/test/java/org/sonar/cxx/AggregateMeasureComputerTest.java
@@ -23,11 +23,11 @@
import org.junit.jupiter.api.Test;
import org.sonar.api.ce.measure.Component;
import org.sonar.api.ce.measure.Component.Type;
-import org.sonar.api.ce.measure.test.TestComponent;
-import org.sonar.api.ce.measure.test.TestComponent.FileAttributesImpl;
-import org.sonar.api.ce.measure.test.TestMeasureComputerContext;
-import org.sonar.api.ce.measure.test.TestMeasureComputerDefinition.MeasureComputerDefinitionBuilderImpl;
-import org.sonar.api.ce.measure.test.TestSettings;
+import org.sonar.api.testfixtures.measure.TestComponent;
+import org.sonar.api.testfixtures.measure.TestComponent.FileAttributesImpl;
+import org.sonar.api.testfixtures.measure.TestMeasureComputerContext;
+import org.sonar.api.testfixtures.measure.TestMeasureComputerDefinition.MeasureComputerDefinitionBuilderImpl;
+import org.sonar.api.testfixtures.measure.TestSettings;
class AggregateMeasureComputerTest {
diff --git a/cxx-squid/src/test/java/org/sonar/cxx/DensityMeasureComputerTest.java b/cxx-squid/src/test/java/org/sonar/cxx/DensityMeasureComputerTest.java
index a3727bff4f..7fada45286 100644
--- a/cxx-squid/src/test/java/org/sonar/cxx/DensityMeasureComputerTest.java
+++ b/cxx-squid/src/test/java/org/sonar/cxx/DensityMeasureComputerTest.java
@@ -22,11 +22,11 @@
import static org.assertj.core.api.Assertions.*;
import org.junit.jupiter.api.Test;
import org.sonar.api.ce.measure.Component.Type;
-import org.sonar.api.ce.measure.test.TestComponent;
-import org.sonar.api.ce.measure.test.TestComponent.FileAttributesImpl;
-import org.sonar.api.ce.measure.test.TestMeasureComputerContext;
-import org.sonar.api.ce.measure.test.TestMeasureComputerDefinition.MeasureComputerDefinitionBuilderImpl;
-import org.sonar.api.ce.measure.test.TestSettings;
+import org.sonar.api.testfixtures.measure.TestComponent;
+import org.sonar.api.testfixtures.measure.TestComponent.FileAttributesImpl;
+import org.sonar.api.testfixtures.measure.TestMeasureComputerContext;
+import org.sonar.api.testfixtures.measure.TestMeasureComputerDefinition.MeasureComputerDefinitionBuilderImpl;
+import org.sonar.api.testfixtures.measure.TestSettings;
class DensityMeasureComputerTest {
diff --git a/cxx-squid/src/test/java/org/sonar/cxx/visitors/CxxParseErrorLoggerVisitorTest.java b/cxx-squid/src/test/java/org/sonar/cxx/visitors/CxxParseErrorLoggerVisitorTest.java
index 7055dbbf3f..72a7b79b00 100644
--- a/cxx-squid/src/test/java/org/sonar/cxx/visitors/CxxParseErrorLoggerVisitorTest.java
+++ b/cxx-squid/src/test/java/org/sonar/cxx/visitors/CxxParseErrorLoggerVisitorTest.java
@@ -22,8 +22,8 @@
import static org.assertj.core.api.Assertions.*;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.RegisterExtension;
-import org.sonar.api.utils.log.LogTesterJUnit5;
-import org.sonar.api.utils.log.LoggerLevel;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
+import org.slf4j.event.Level;
import org.sonar.cxx.CxxAstScanner;
import org.sonar.cxx.CxxFileTesterHelper;
@@ -34,11 +34,11 @@ class CxxParseErrorLoggerVisitorTest {
@Test
void handleParseErrorTest() throws Exception {
- logTester.setLevel(LoggerLevel.DEBUG);
+ logTester.setLevel(Level.DEBUG);
var tester = CxxFileTesterHelper.create("src/test/resources/visitors/syntaxerror.cc", ".", "");
CxxAstScanner.scanSingleInputFile(tester.asInputFile());
- var log = String.join("\n", logTester.logs(LoggerLevel.DEBUG));
+ var log = String.join("\n", logTester.logs(Level.DEBUG));
assertThat(log)
.isNotEmpty()
diff --git a/cxx-sslr-toolkit/pom.xml b/cxx-sslr-toolkit/pom.xml
index 88e5aa053f..b730d0a27c 100644
--- a/cxx-sslr-toolkit/pom.xml
+++ b/cxx-sslr-toolkit/pom.xml
@@ -103,7 +103,7 @@
- 8500000
+ 8600000
6000000
${project.build.directory}/${project.build.finalName}.jar
diff --git a/cxx-sslr/sslr-core/src/test/java/com/sonar/cxx/sslr/impl/typed/InterceptorTest.java b/cxx-sslr/sslr-core/src/test/java/com/sonar/cxx/sslr/impl/typed/InterceptorTest.java
index c93a6afe0c..de7d1cf47b 100644
--- a/cxx-sslr/sslr-core/src/test/java/com/sonar/cxx/sslr/impl/typed/InterceptorTest.java
+++ b/cxx-sslr/sslr-core/src/test/java/com/sonar/cxx/sslr/impl/typed/InterceptorTest.java
@@ -170,7 +170,7 @@ void requires_final_methods_to_be_non_public() {
var thrown = catchThrowableOfType(() -> Interceptor.create(PublicFinalMethod.class, new Class[]{},
new Object[]{},
methodInterceptor),
- VerifyError.class);
+ IncompatibleClassChangeError.class);
assertThat(thrown)
// Note that details of the message are different between JDK versions
.hasMessageStartingWith("class GeneratedBySSLR overrides final method");
diff --git a/integration-tests/features/smoketest.feature b/integration-tests/features/smoketest.feature
index 940e03d997..99bc21d289 100644
--- a/integration-tests/features/smoketest.feature
+++ b/integration-tests/features/smoketest.feature
@@ -30,7 +30,6 @@ Feature: Smoketests
| statements | 36 |
| classes | 1 |
| files | 8 |
- | directories | None |
| functions | 5 |
| comment_lines_density | 30 |
| comment_lines | 24 |
@@ -95,7 +94,6 @@ Feature: Smoketests
| statements | 36 |
| classes | 1 |
| files | 8 |
- | directories | None |
| functions | 5 |
| comment_lines_density | 30 |
| comment_lines | 24 |
@@ -160,7 +158,6 @@ Feature: Smoketests
| statements | 36 |
| classes | 1 |
| files | 8 |
- | directories | None |
| functions | 5 |
| comment_lines_density | 30 |
| comment_lines | 24 |
diff --git a/integration-tests/features/steps/test_execution_statistics.py b/integration-tests/features/steps/test_execution_statistics.py
index 2d9203a839..87c7c27c5a 100644
--- a/integration-tests/features/steps/test_execution_statistics.py
+++ b/integration-tests/features/steps/test_execution_statistics.py
@@ -146,7 +146,7 @@ def step_impl(context, rule):
def step_impl(context, rule, templaterule, repository):
assert context.profile_key != '', f"PROFILE KEY NOT FOUND: {str(context.profile_key)}"
url = ('/api/rules/create')
- payload = {'custom_key': rule, 'html_description': 'nodesc', 'name': rule, 'severity': 'MAJOR', 'template_key': templaterule, 'markdown_description': 'nodesc'}
+ payload = {'customKey': rule, 'html_description': 'nodesc', 'name': rule, 'severity': 'MAJOR', 'templateKey': templaterule, 'markdownDescription': 'nodesc'}
web_api_set(url, payload)
url = ('/api/qualityprofiles/activate_rule')
payload = {'key': context.profile_key, 'rule': repository + ':' + rule, 'severity': 'MAJOR'}
diff --git a/pom.xml b/pom.xml
index b9a8467dd2..3b4b045b57 100644
--- a/pom.xml
+++ b/pom.xml
@@ -261,8 +261,8 @@
integration-tests/target/site/jacoco-aggregate/jacoco.xml
- 9.9.0.65466
- 9.14.0.375
+ 10.3.0.82913
+ 10.3.0.1951
8.9
@@ -290,7 +290,7 @@
6.6.0
- 11
+ 17
2.7.3
1.0.0
3.12.1
@@ -313,6 +313,11 @@
sonar-plugin-api
${sonar.plugin.api.version}
+
+ org.sonarsource.api.plugin
+ sonar-plugin-api-test-fixtures
+ ${sonar.plugin.api.version}
+
org.sonarsource.sonarqube
sonar-plugin-api-impl
@@ -324,6 +329,12 @@
${sonar.version}
+
+ org.slf4j
+ slf4j-api
+ 1.7.30
+
+
commons-io
commons-io
@@ -458,7 +469,18 @@
org.apache.maven.plugins
maven-compiler-plugin
-
+
+ org.apache.maven.plugins
+ maven-surefire-plugin
+ 2.22.2
+
+
+ @{argLine}
+ --add-opens=java.base/java.lang=ALL-UNNAMED
+ --add-opens=java.base/java.util=ALL-UNNAMED
+
+
+
diff --git a/sonar-cxx-plugin/pom.xml b/sonar-cxx-plugin/pom.xml
index 35a5b84a34..b173762994 100644
--- a/sonar-cxx-plugin/pom.xml
+++ b/sonar-cxx-plugin/pom.xml
@@ -32,11 +32,21 @@
sonar-plugin-api
provided
+
+ org.sonarsource.api.plugin
+ sonar-plugin-api-test-fixtures
+ provided
+
org.sonarsource.sonarqube
sonar-plugin-api-impl
test
+
+ org.slf4j
+ slf4j-api
+ provided
+
${project.groupId}
cxx-squid
diff --git a/sonar-cxx-plugin/src/test/java/org/sonar/plugins/cxx/DroppedPropertiesSensorTest.java b/sonar-cxx-plugin/src/test/java/org/sonar/plugins/cxx/DroppedPropertiesSensorTest.java
index 5e5a5693a4..21c9e27179 100644
--- a/sonar-cxx-plugin/src/test/java/org/sonar/plugins/cxx/DroppedPropertiesSensorTest.java
+++ b/sonar-cxx-plugin/src/test/java/org/sonar/plugins/cxx/DroppedPropertiesSensorTest.java
@@ -28,8 +28,8 @@
import org.junit.jupiter.api.io.TempDir;
import org.sonar.api.batch.sensor.internal.SensorContextTester;
import org.sonar.api.config.internal.MapSettings;
-import org.sonar.api.utils.log.LogTesterJUnit5;
-import org.sonar.api.utils.log.LoggerLevel;
+import org.sonar.api.testfixtures.log.LogTesterJUnit5;
+import org.slf4j.event.Level;
class DroppedPropertiesSensorTest {
@@ -48,7 +48,7 @@ void testNoMsg() throws Exception {
var sensor = new DroppedPropertiesSensor(analysisWarnings::add);
sensor.execute(contextTester);
- assertThat(logTester.logs(LoggerLevel.WARN)).isEmpty();
+ assertThat(logTester.logs(Level.WARN)).isEmpty();
assertThat(analysisWarnings).isEmpty();
}
@@ -62,7 +62,7 @@ void testNoLongerSupported() throws Exception {
sensor.execute(contextTester);
var msg = "CXX property 'sonar.cxx.cppncss.reportPaths' is no longer supported.";
- assertThat(logTester.logs(LoggerLevel.WARN)).contains(msg);
+ assertThat(logTester.logs(Level.WARN)).contains(msg);
assertThat(analysisWarnings).containsExactly(msg);
}
@@ -77,7 +77,7 @@ void testNoLongerSupportedWithInfo() throws Exception {
var msg = "CXX property 'sonar.cxx.suffixes.sources' is no longer supported."
+ " Use key 'sonar.cxx.file.suffixes' instead.";
- assertThat(logTester.logs(LoggerLevel.WARN)).contains(msg);
+ assertThat(logTester.logs(Level.WARN)).contains(msg);
assertThat(analysisWarnings).containsExactly(msg);
}