summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2012-10-23 17:48:48 -0400
committerJames Moger <james.moger@gitblit.com>2012-10-23 17:48:48 -0400
commit1c817663269b52065b79eba37f29a5a4f67348d1 (patch)
tree55252c94c493592225f1a79ca43aceb2a48a27f7 /tests
parent2bfb8ab137ac18b60cad0c375c7b9bef67499b94 (diff)
downloadgitblit-1c817663269b52065b79eba37f29a5a4f67348d1.tar.gz
gitblit-1c817663269b52065b79eba37f29a5a4f67348d1.zip
Fix broken unit test on Windows
Diffstat (limited to 'tests')
-rw-r--r--tests/com/gitblit/tests/GitServletTest.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/com/gitblit/tests/GitServletTest.java b/tests/com/gitblit/tests/GitServletTest.java
index 17d462ac..e65c61cb 100644
--- a/tests/com/gitblit/tests/GitServletTest.java
+++ b/tests/com/gitblit/tests/GitServletTest.java
@@ -611,11 +611,13 @@ public class GitServletTest {
}
File personalRepo = new File(GitBlitSuite.REPOSITORIES, MessageFormat.format("~{0}/ticgit.git", user.username));
+ GitBlitSuite.close(personalRepo);
if (personalRepo.exists()) {
FileUtils.delete(personalRepo, FileUtils.RECURSIVE);
}
File projectRepo = new File(GitBlitSuite.REPOSITORIES, "project/ticgit.git");
+ GitBlitSuite.close(projectRepo);
if (projectRepo.exists()) {
FileUtils.delete(projectRepo, FileUtils.RECURSIVE);
}
@@ -628,6 +630,8 @@ public class GitServletTest {
clone.setCredentialsProvider(cp);
Git git = clone.call();
+ GitBlitSuite.close(personalRepo);
+
// add a personal repository remote and a project remote
git.getRepository().getConfig().setString("remote", "user", "url", MessageFormat.format("{0}/git/~{1}/ticgit.git", url, user.username));
git.getRepository().getConfig().setString("remote", "project", "url", MessageFormat.format("{0}/git/project/ticgit.git", url));