From 5d253a0fba287a01779dde5ec932598bb8876426 Mon Sep 17 00:00:00 2001
From: Trygve Laugstøl <trygvis@inamo.no>
Date: Mon, 10 Oct 2011 10:49:29 -0400
Subject: [PATCH] o Adding support for customizing the webapp's context path.
---
tests/com/gitblit/tests/JGitUtilsTest.java | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/tests/com/gitblit/tests/JGitUtilsTest.java b/tests/com/gitblit/tests/JGitUtilsTest.java
index 0841da3..0d7aa63 100644
--- a/tests/com/gitblit/tests/JGitUtilsTest.java
+++ b/tests/com/gitblit/tests/JGitUtilsTest.java
@@ -33,6 +33,7 @@
import org.eclipse.jgit.lib.RepositoryCache.FileKey;
import org.eclipse.jgit.revwalk.RevCommit;
import org.eclipse.jgit.util.FS;
+import org.eclipse.jgit.util.FileUtils;
import com.gitblit.GitBlit;
import com.gitblit.Keys;
@@ -197,6 +198,13 @@
.equals("183474d554e6f68478a02d9d7888b67a9338cdff"));
}
+ public void testCreateOrphanedBranch() throws Exception {
+ Repository repository = JGitUtils.createRepository(GitBlitSuite.REPOSITORIES, "orphantest");
+ assertTrue(JGitUtils.createOrphanBranch(repository,
+ "x" + Long.toHexString(System.currentTimeMillis()).toUpperCase()));
+ FileUtils.delete(repository.getDirectory(), FileUtils.RECURSIVE);
+ }
+
public void testStringContent() throws Exception {
Repository repository = GitBlitSuite.getHelloworldRepository();
String contentA = JGitUtils.getStringContent(repository, null, "java.java");
@@ -357,4 +365,5 @@
assertTrue(zipFileB.length() > 0);
zipFileB.delete();
}
+
}
\ No newline at end of file
--
Gitblit v1.9.1