aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-batch/src
diff options
context:
space:
mode:
authorDuarte Meneses <duarte.meneses@sonarsource.com>2016-03-15 14:58:03 +0100
committerDuarte Meneses <duarte.meneses@sonarsource.com>2016-03-15 15:31:44 +0100
commitc189245cda6020e46179bb1d0c9f54497440883b (patch)
tree3f9786f639b167389acdb84cefd6f5c8cd6b09b0 /sonar-batch/src
parent35f6a66273ba7ee5815b1c35446f17da9b1b6f0b (diff)
downloadsonarqube-c189245cda6020e46179bb1d0c9f54497440883b.tar.gz
sonarqube-c189245cda6020e46179bb1d0c9f54497440883b.zip
SONAR-6719 Wrong casing when indexing individual files lead to issue during scm blame
Diffstat (limited to 'sonar-batch/src')
-rw-r--r--sonar-batch/src/test/java/org/sonar/batch/mediumtest/fs/FileSystemMediumTest.java17
1 files changed, 17 insertions, 0 deletions
diff --git a/sonar-batch/src/test/java/org/sonar/batch/mediumtest/fs/FileSystemMediumTest.java b/sonar-batch/src/test/java/org/sonar/batch/mediumtest/fs/FileSystemMediumTest.java
index 564a8ce247f..bb669ceec00 100644
--- a/sonar-batch/src/test/java/org/sonar/batch/mediumtest/fs/FileSystemMediumTest.java
+++ b/sonar-batch/src/test/java/org/sonar/batch/mediumtest/fs/FileSystemMediumTest.java
@@ -234,6 +234,23 @@ public class FileSystemMediumTest {
.start();
assertThat(result.inputFiles()).hasSize(3);
+ // check that symlink was not resolved to target
+ assertThat(result.inputFiles()).extractingResultOf("path").toString().startsWith(projectDir.toString());
+ }
+ }
+
+ // SONAR-6719
+ @Test
+ public void scanProjectWithWrongCase() {
+ if (System2.INSTANCE.isOsWindows()) {
+ File projectDir = new File("src/test/resources/mediumtest/xoo/sample");
+ TaskResult result = tester
+ .newScanTask(new File(projectDir, "sonar-project.properties"))
+ .property("sonar.sources", "SRC")
+ .start();
+
+ assertThat(result.inputFiles()).hasSize(3);
+ assertThat(result.inputFiles()).extractingResultOf("relativePath").startsWith("src");
}
}