Skip to content

Commit 6e96592

Browse files
Vladimir Kotalahornace
authored andcommitted
cleanup EnabledForRepository.GIT
1 parent faef126 commit 6e96592

File tree

13 files changed

+7
-35
lines changed

13 files changed

+7
-35
lines changed

dev/before

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
echo "SCM versions:"
44
if command -v bk; then bk --version; fi
55
if command -v hg; then hg --version; fi
6-
if command -v git; then git --version; fi
76
if command -v svn; then svn --version; fi
87
if command -v cvs; then cvs --version; fi
98
if command -v mtn; then mtn --version; fi

opengrok-indexer/src/test/java/org/opengrok/indexer/condition/RepositoryInstalled.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
import org.opengrok.indexer.history.BazaarRepository;
2828
import org.opengrok.indexer.history.BitKeeperRepository;
2929
import org.opengrok.indexer.history.CVSRepository;
30-
import org.opengrok.indexer.history.GitRepository;
3130
import org.opengrok.indexer.history.MercurialRepository;
3231
import org.opengrok.indexer.history.PerforceRepository;
3332
import org.opengrok.indexer.history.RCSRepository;
@@ -42,7 +41,6 @@ public class RepositoryInstalled {
4241
public enum Type {
4342
BITKEEPER(new BitKeeperRepository()),
4443
MERCURIAL(new MercurialRepository()),
45-
GIT(new GitRepository()),
4644
RCS(new RCSRepository()),
4745
BAZAAR(new BazaarRepository()),
4846
CVS(new CVSRepository()),

opengrok-indexer/src/test/java/org/opengrok/indexer/history/FileHistoryCacheOctopusTest.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
import org.junit.jupiter.api.AfterEach;
2727
import org.junit.jupiter.api.BeforeEach;
2828
import org.junit.jupiter.api.Test;
29-
import org.opengrok.indexer.condition.EnabledForRepository;
3029
import org.opengrok.indexer.configuration.RuntimeEnvironment;
3130
import org.opengrok.indexer.util.TestRepository;
3231

@@ -35,7 +34,6 @@
3534

3635
import static org.junit.jupiter.api.Assertions.assertEquals;
3736
import static org.junit.jupiter.api.Assertions.assertNotNull;
38-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
3937

4038
/**
4139
* Test file-based history cache with for git-octopus.
@@ -65,7 +63,6 @@ public void tearDown() {
6563
cache = null;
6664
}
6765

68-
@EnabledForRepository(GIT)
6966
@Test
7067
public void testStoreAndGet() throws Exception {
7168
File reposRoot = new File(repositories.getSourceRoot(), "git-octopus");

opengrok-indexer/src/test/java/org/opengrok/indexer/history/GitRepositoryOctopusTest.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,10 @@
2626
import static org.junit.jupiter.api.Assertions.assertEquals;
2727
import static org.junit.jupiter.api.Assertions.assertNotNull;
2828
import static org.junit.jupiter.api.Assertions.assertTrue;
29-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
3029

3130
import org.junit.jupiter.api.AfterAll;
3231
import org.junit.jupiter.api.BeforeAll;
3332
import org.junit.jupiter.api.Test;
34-
import org.opengrok.indexer.condition.EnabledForRepository;
3533
import org.opengrok.indexer.configuration.RuntimeEnvironment;
3634
import org.opengrok.indexer.util.TestRepository;
3735
import org.opengrok.indexer.web.Util;
@@ -45,7 +43,6 @@
4543
/**
4644
* @author austvik
4745
*/
48-
@EnabledForRepository(GIT)
4946
public class GitRepositoryOctopusTest {
5047

5148
private static TestRepository repository = new TestRepository();

opengrok-indexer/src/test/java/org/opengrok/indexer/history/HistoryGuruTest.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import static org.junit.jupiter.api.Assertions.assertNotNull;
2929
import static org.junit.jupiter.api.Assertions.assertTrue;
3030
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.CVS;
31-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
3231
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.MERCURIAL;
3332
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.SUBVERSION;
3433

@@ -152,7 +151,6 @@ public void getCacheInfo() throws HistoryException {
152151
}
153152

154153
@Test
155-
@EnabledForRepository(GIT)
156154
public void testAddRemoveRepositories() {
157155
HistoryGuru instance = HistoryGuru.getInstance();
158156
final int numReposOrig = instance.getRepositories().size();
@@ -177,7 +175,7 @@ public void testAddRemoveRepositories() {
177175
}
178176

179177
@Test
180-
@EnabledForRepository({CVS, GIT})
178+
@EnabledForRepository(CVS)
181179
public void testAddSubRepositoryNotNestable() {
182180
HistoryGuru instance = HistoryGuru.getInstance();
183181

@@ -251,7 +249,6 @@ private static void certainlyMkdirs(File file) throws IOException {
251249
}
252250

253251
@Test
254-
@EnabledForRepository(GIT)
255252
public void testScanningDepth() throws IOException {
256253
String topLevelDirName = "scanDepthTest";
257254
File repoRoot = new File(repository.getSourceRoot(), topLevelDirName);

opengrok-indexer/src/test/java/org/opengrok/indexer/index/IndexDatabaseSymlinksTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
* Represents a container for additional tests of {@link IndexDatabase} for symlinks.
5454
*/
5555
@EnabledOnOs({OS.LINUX, OS.MAC, OS.SOLARIS, OS.AIX, OS.OTHER})
56-
@EnabledForRepository({RepositoryInstalled.Type.GIT, RepositoryInstalled.Type.MERCURIAL})
56+
@EnabledForRepository(RepositoryInstalled.Type.MERCURIAL)
5757
public class IndexDatabaseSymlinksTest {
5858

5959
private static RuntimeEnvironment env;

opengrok-indexer/src/test/java/org/opengrok/indexer/index/IndexerRepoTest.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
import static org.junit.jupiter.api.Assertions.assertNotNull;
3838
import static org.junit.jupiter.api.Assertions.assertNull;
3939
import static org.junit.jupiter.api.Assertions.assertTrue;
40-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
4140
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.MERCURIAL;
4241

4342
import org.junit.jupiter.api.AfterEach;
@@ -77,7 +76,7 @@ public void tearDown() {
7776
* Test it is possible to disable history per project.
7877
*/
7978
@Test
80-
@EnabledForRepository({MERCURIAL, GIT})
79+
@EnabledForRepository(MERCURIAL)
8180
public void testPerProjectHistoryGlobalOn() throws IndexerException, IOException, HistoryException {
8281
testPerProjectHistory(true);
8382
}
@@ -86,7 +85,7 @@ public void testPerProjectHistoryGlobalOn() throws IndexerException, IOException
8685
* Test it is possible to enable history per project.
8786
*/
8887
@Test
89-
@EnabledForRepository({MERCURIAL, GIT})
88+
@EnabledForRepository(MERCURIAL)
9089
public void testPerProjectHistoryGlobalOff() throws IndexerException, IOException, HistoryException {
9190
testPerProjectHistory(false);
9291
}

opengrok-indexer/src/test/java/org/opengrok/indexer/index/IndexerTest.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import static org.junit.jupiter.api.Assertions.assertNotEquals;
3030
import static org.junit.jupiter.api.Assertions.assertNotNull;
3131
import static org.junit.jupiter.api.Assertions.assertTrue;
32-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
3332
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.MERCURIAL;
3433

3534
import java.io.BufferedWriter;
@@ -366,7 +365,7 @@ public void testRemoveFileOnFileChange() throws Exception {
366365
}
367366

368367
@Test
369-
@EnabledForRepository({MERCURIAL, GIT})
368+
@EnabledForRepository(MERCURIAL)
370369
public void testSetRepositories() throws Exception {
371370
RuntimeEnvironment env = RuntimeEnvironment.getInstance();
372371

opengrok-web/src/test/java/org/opengrok/web/PageConfigTest.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@
5757
import static org.junit.jupiter.api.Assertions.assertThrows;
5858
import static org.junit.jupiter.api.Assertions.assertTrue;
5959
import static org.junit.jupiter.api.Assumptions.assumeTrue;
60-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
6160
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.MERCURIAL;
6261

6362
/**
@@ -257,7 +256,6 @@ public String getParameter(String name) {
257256
}
258257

259258
@Test
260-
@EnabledForRepository(GIT)
261259
public void testGetLatestRevisionValid() {
262260
DummyHttpServletRequest req1 = new DummyHttpServletRequest() {
263261
@Override
@@ -273,7 +271,6 @@ public String getPathInfo() {
273271
}
274272

275273
@Test
276-
@EnabledForRepository(GIT)
277274
public void testGetRevisionLocation() {
278275
DummyHttpServletRequest req1 = new DummyHttpServletRequest() {
279276
@Override
@@ -300,7 +297,6 @@ public String getQueryString() {
300297
}
301298

302299
@Test
303-
@EnabledForRepository(GIT)
304300
public void testGetRevisionLocationNullQuery() {
305301
DummyHttpServletRequest req1 = new DummyHttpServletRequest() {
306302
@Override
@@ -327,7 +323,6 @@ public String getQueryString() {
327323
}
328324

329325
@Test
330-
@EnabledForRepository(GIT)
331326
public void testGetLatestRevisionNotValid() {
332327
DummyHttpServletRequest req2 = new DummyHttpServletRequest() {
333328
@Override
@@ -368,7 +363,6 @@ public String getParameter(String name) {
368363
}
369364

370365
@Test
371-
@EnabledForRepository(GIT)
372366
public void testGetAnnotation() {
373367
final String[] revisions = {"aa35c258", "bb74b7e8"};
374368

opengrok-web/src/test/java/org/opengrok/web/api/v1/controller/AnnotationControllerTest.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import org.junit.jupiter.api.AfterEach;
3030
import org.junit.jupiter.api.BeforeEach;
3131
import org.junit.jupiter.api.Test;
32-
import org.opengrok.indexer.condition.EnabledForRepository;
3332
import org.opengrok.indexer.configuration.RuntimeEnvironment;
3433
import org.opengrok.indexer.history.HistoryGuru;
3534
import org.opengrok.indexer.history.RepositoryFactory;
@@ -50,9 +49,7 @@
5049

5150
import static org.junit.jupiter.api.Assertions.assertEquals;
5251
import static org.junit.jupiter.api.Assertions.assertTrue;
53-
import static org.opengrok.indexer.condition.RepositoryInstalled.Type.GIT;
5452

55-
@EnabledForRepository(GIT)
5653
public class AnnotationControllerTest extends OGKJerseyTest {
5754

5855
private final RuntimeEnvironment env = RuntimeEnvironment.getInstance();

0 commit comments

Comments
 (0)