diff options
Diffstat (limited to 'tests/projects/duplications/cross-module/module1')
5 files changed, 65 insertions, 0 deletions
diff --git a/tests/projects/duplications/cross-module/module1/sonar-project.properties b/tests/projects/duplications/cross-module/module1/sonar-project.properties new file mode 100644 index 00000000000..a4b8c4853a5 --- /dev/null +++ b/tests/projects/duplications/cross-module/module1/sonar-project.properties @@ -0,0 +1,5 @@ +sonar.projectKey=module1 +sonar.projectName=Module 1 +sonar.projectVersion=1.0-SNAPSHOT +sonar.sources=src/main/xoo +sonar.language=xoo diff --git a/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo new file mode 100644 index 00000000000..5e494b196ab --- /dev/null +++ b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo @@ -0,0 +1,35 @@ +package sample; + +public class File1 { + + public File1() { + } + + public void test() { + char[] charList = new char[30]; + for (int i = 0; i < 10; i++) { + charList[i] = 'a'; + } + for (int i = 0; i < 10; i++) { + charList[i] = 'a'; + } + int intergerToBeIncremented = 0; + while (intergerToBeIncremented < 100) { + intergerToBeIncremented++; + } + int intergerToBeIncremented2 = 0; + while (intergerToBeIncremented2 < 100) { + intergerToBeIncremented2++; + } + String temp = ""; + for (int i=0; i<10; i++){ + temp += "say something"+i; + } + for (int i=0; i<20; i++){ + temp += "say nothing"+i; + } + for (int i=0; i<30; i++){ + temp += "always say nothing"+i; + } + } +} diff --git a/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo.measures b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo.measures new file mode 100644 index 00000000000..5a79b0b5dbb --- /dev/null +++ b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File1.xoo.measures @@ -0,0 +1 @@ +ncloc:36 diff --git a/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo new file mode 100644 index 00000000000..00b502d423a --- /dev/null +++ b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo @@ -0,0 +1,23 @@ +package sample; + +public class File1 { + + public File1() { + } + + public void otherMethod() { + String temp = ""; + for (int i=0; i<10; i++){ + temp += "say something"+i; + int nothing = 0; + } + for (int i=0; i<20; i++){ + temp += "say nothing"+i; + int nothing = 1; + } + for (int i=0; i<30; i++){ + temp += "always say nothing"+i; + int nothing = 2; + } + } +} diff --git a/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo.measures b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo.measures new file mode 100644 index 00000000000..d90983a3e9f --- /dev/null +++ b/tests/projects/duplications/cross-module/module1/src/main/xoo/sample/File2.xoo.measures @@ -0,0 +1 @@ +ncloc:24 |