diff options
author | Simon Brandhof <simon.brandhof@sonarsource.com> | 2015-06-29 15:53:56 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@sonarsource.com> | 2015-06-29 19:01:12 +0200 |
commit | 501289ca85e1c8dd21d5e0ba5f457b40ee62f5ef (patch) | |
tree | ba5b06c4357edb58ec3f248c6fa12324c1ec71ca /server/sonar-server-benchmarks | |
parent | fcf0d15e049e9c6e647fae628dc0e2bc17d078b6 (diff) | |
download | sonarqube-501289ca85e1c8dd21d5e0ba5f457b40ee62f5ef.tar.gz sonarqube-501289ca85e1c8dd21d5e0ba5f457b40ee62f5ef.zip |
Quality flaws
- do not declare multiple variables on same line
- fix imports
Diffstat (limited to 'server/sonar-server-benchmarks')
2 files changed, 17 insertions, 6 deletions
diff --git a/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/IssueIndexBenchmarkTest.java b/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/IssueIndexBenchmarkTest.java index 398317ba38e..e5fe44f9283 100644 --- a/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/IssueIndexBenchmarkTest.java +++ b/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/IssueIndexBenchmarkTest.java @@ -147,8 +147,11 @@ public class IssueIndexBenchmarkTest { } private static class IssueIterator implements Iterator<IssueDoc> { - private final int nbProjects, nbFilesPerProject, nbIssuesPerFile; - private int currentProject = 0, currentFile = 0; + private final int nbProjects; + private final int nbFilesPerProject; + private final int nbIssuesPerFile; + private int currentProject = 0; + private int currentFile = 0; private AtomicLong count = new AtomicLong(0L); private final Iterator<String> users = cycleIterator("guy", 200); private Iterator<String> rules = cycleIterator("squid:rule", 1000); diff --git a/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/SourceIndexBenchmarkTest.java b/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/SourceIndexBenchmarkTest.java index b050c237ebe..c1c529d7cb0 100644 --- a/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/SourceIndexBenchmarkTest.java +++ b/server/sonar-server-benchmarks/src/test/java/org/sonar/server/benchmark/SourceIndexBenchmarkTest.java @@ -20,6 +20,12 @@ package org.sonar.server.benchmark; +import java.util.Arrays; +import java.util.Date; +import java.util.Iterator; +import java.util.List; +import java.util.Timer; +import java.util.concurrent.atomic.AtomicLong; import org.apache.commons.io.FileUtils; import org.junit.Rule; import org.junit.Test; @@ -27,12 +33,14 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.sonar.server.es.EsClient; import org.sonar.server.source.db.FileSourceDb; -import org.sonar.server.source.index.*; +import org.sonar.server.source.index.FileSourcesUpdaterHelper; +import org.sonar.server.source.index.SourceLineDoc; +import org.sonar.server.source.index.SourceLineIndex; +import org.sonar.server.source.index.SourceLineIndexDefinition; +import org.sonar.server.source.index.SourceLineIndexer; +import org.sonar.server.source.index.SourceLineResultSetIterator; import org.sonar.server.tester.ServerTester; -import java.util.*; -import java.util.concurrent.atomic.AtomicLong; - import static org.assertj.core.api.Assertions.assertThat; /** |