aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-scanner-engine/src/test/java/org/sonar/scm
diff options
context:
space:
mode:
authorMatteo Mara <matteo.mara@sonarsource.com>2023-12-04 12:50:58 +0100
committersonartech <sonartech@sonarsource.com>2023-12-04 20:03:22 +0000
commitd62a56ecfd4cf2f183873900fd32cffc4743c7fb (patch)
tree552481ceb8b8cab34f74b59563b58278ffa62f69 /sonar-scanner-engine/src/test/java/org/sonar/scm
parentcdda3dbcdd4e4b5f4a2e7471a37fa66877e26aad (diff)
downloadsonarqube-d62a56ecfd4cf2f183873900fd32cffc4743c7fb.tar.gz
sonarqube-d62a56ecfd4cf2f183873900fd32cffc4743c7fb.zip
SONAR-21174 Fix code smells raised after dropping JDK11 support
Diffstat (limited to 'sonar-scanner-engine/src/test/java/org/sonar/scm')
-rw-r--r--sonar-scanner-engine/src/test/java/org/sonar/scm/git/CompositeBlameCommandIT.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/sonar-scanner-engine/src/test/java/org/sonar/scm/git/CompositeBlameCommandIT.java b/sonar-scanner-engine/src/test/java/org/sonar/scm/git/CompositeBlameCommandIT.java
index 3178cf68327..74ad0ba414c 100644
--- a/sonar-scanner-engine/src/test/java/org/sonar/scm/git/CompositeBlameCommandIT.java
+++ b/sonar-scanner-engine/src/test/java/org/sonar/scm/git/CompositeBlameCommandIT.java
@@ -100,7 +100,7 @@ public class CompositeBlameCommandIT {
"dummy-git-few-comitters"
);
- List<BlameAlgorithmEnum> blameStrategies = Arrays.stream(BlameAlgorithmEnum.values()).collect(Collectors.toList());
+ List<BlameAlgorithmEnum> blameStrategies = Arrays.stream(BlameAlgorithmEnum.values()).toList();
return testCases.stream()
.flatMap(t -> blameStrategies.stream().map(b -> new Object[]{t, b}))
.toArray(Object[][]::new);
@@ -128,7 +128,7 @@ public class CompositeBlameCommandIT {
Path expectedBlameFiles = new File(Utils.class.getResource("expected-blame/" + expectedBlameFolder).toURI()).toPath();
Map<Path, List<BlameLine>> expectedBlame = new HashMap<>();
- List<Path> filesInExpectedBlameFolder = Files.walk(expectedBlameFiles).filter(Files::isRegularFile).collect(Collectors.toList());
+ List<Path> filesInExpectedBlameFolder = Files.walk(expectedBlameFiles).filter(Files::isRegularFile).toList();
for (Path expectedFileBlamePath : filesInExpectedBlameFolder) {
List<BlameLine> blameLines = new ArrayList<>();
List<String> expectedBlameStrings = Files.readAllLines(expectedFileBlamePath);