Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Wolf2019-03-24 12:35:19 -0400
committerThomas Wolf2019-03-24 13:54:51 -0400
commitd4ecfa96d4f693fc793fc8bba7d69ae593adcbdf (patch)
treee7356a2f2b662537fdb3064f95577fc5456a1ce7 /org.eclipse.egit.ui.test/src
parent3000aee9af8f207e7304259bba4b8ba422aeb981 (diff)
downloadegit-d4ecfa96d4f693fc793fc8bba7d69ae593adcbdf.tar.gz
egit-d4ecfa96d4f693fc793fc8bba7d69ae593adcbdf.tar.xz
egit-d4ecfa96d4f693fc793fc8bba7d69ae593adcbdf.zip
Try to stabilize tests
Ignore one test; close a repository in another. Change-Id: I6a25f1296c5e7aefb3afd5ec6b90691b258a5128 Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
Diffstat (limited to 'org.eclipse.egit.ui.test/src')
-rw-r--r--org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewRepoDeletionTest.java2
-rw-r--r--org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/wizards/clone/GitCloneWizardTest.java32
2 files changed, 20 insertions, 14 deletions
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewRepoDeletionTest.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewRepoDeletionTest.java
index 6776ee900..03d751b9d 100644
--- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewRepoDeletionTest.java
+++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewRepoDeletionTest.java
@@ -47,6 +47,7 @@ import org.eclipse.swtbot.swt.finder.widgets.SWTBotShell;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
import org.junit.Before;
+import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
@@ -147,6 +148,7 @@ public class GitRepositoriesViewRepoDeletionTest extends
new File(repositoryFile.getParentFile(), PROJ1).isDirectory());
}
+ @Ignore("This test is too unstable on the new Kubernetes infrastructure")
@Test
public void testRemoveRepositoryRemoveFromCachesBug483664()
throws Exception {
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/wizards/clone/GitCloneWizardTest.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/wizards/clone/GitCloneWizardTest.java
index f7b4a4ff9..2d8cc4d91 100644
--- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/wizards/clone/GitCloneWizardTest.java
+++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/wizards/clone/GitCloneWizardTest.java
@@ -249,20 +249,24 @@ public class GitCloneWizardTest extends GitCloneWizardTestBase {
// the integrity of the repository here. Only a few basic properties
// we'd expect from a clone made this way, that would possibly
// not hold true given other parameters in the GUI.
- Repository repository = FileRepositoryBuilder.create(new File(destRepo,
- Constants.DOT_GIT));
- assertNotNull(repository.resolve("src/" + SampleTestRepository.FIX));
- // we didn't clone that one
- assertNull(repository.resolve("src/master"));
- // and a local master initialized from origin/master (default!)
- assertEquals(repository.resolve("stable"), repository
- .resolve("src/stable"));
- // A well known tag
- assertNotNull(repository.resolve(Constants.R_TAGS + SampleTestRepository.v2_0_name).name());
- // lots of refs
- assertTrue(repository.getRefDatabase().getRefsByPrefix(RefDatabase.ALL)
- .size() >= 4);
- bot.button("Cancel").click();
+ try (Repository repository = FileRepositoryBuilder
+ .create(new File(destRepo, Constants.DOT_GIT))) {
+ assertNotNull(
+ repository.resolve("src/" + SampleTestRepository.FIX));
+ // we didn't clone that one
+ assertNull(repository.resolve("src/master"));
+ // and a local master initialized from origin/master (default!)
+ assertEquals(repository.resolve("stable"),
+ repository.resolve("src/stable"));
+ // A well known tag
+ assertNotNull(repository
+ .resolve(Constants.R_TAGS + SampleTestRepository.v2_0_name)
+ .name());
+ // lots of refs
+ assertTrue(repository.getRefDatabase()
+ .getRefsByPrefix(RefDatabase.ALL).size() >= 4);
+ bot.button("Cancel").click();
+ }
}
// TODO network timeouts seem to be longer on central EGit build

Back to the top