From 28d6b2a860740557bf93dd0f9a48d059379ed696 Mon Sep 17 00:00:00 2001
From: James Moger <james.moger@gitblit.com>
Date: Sat, 28 May 2011 17:05:34 -0400
Subject: [PATCH] Unit testing. Removal of some unused code paths.

---
 tests/com/gitblit/tests/GitBlitSuite.java |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/tests/com/gitblit/tests/GitBlitSuite.java b/tests/com/gitblit/tests/GitBlitSuite.java
index a31b013..63c2646 100644
--- a/tests/com/gitblit/tests/GitBlitSuite.java
+++ b/tests/com/gitblit/tests/GitBlitSuite.java
@@ -11,6 +11,10 @@
 import org.eclipse.jgit.lib.Repository;
 import org.eclipse.jgit.storage.file.FileRepository;
 
+import com.gitblit.FileSettings;
+import com.gitblit.GitBlit;
+import com.gitblit.JettyLoginService;
+
 public class GitBlitSuite extends TestSetup {
 	public static final File REPOSITORIES = new File("git");
 
@@ -20,7 +24,9 @@
 
 	public static Test suite() {
 		TestSuite suite = new TestSuite();
+		suite.addTestSuite(TimeUtilsTest.class);
 		suite.addTestSuite(JGitUtilsTest.class);
+		suite.addTestSuite(GitBlitTest.class);
 		return new GitBlitSuite(suite);
 	}
 
@@ -39,6 +45,11 @@
 			cloneOrFetch("nested/helloworld.git", "https://github.com/git/hello-world.git", true);
 			cloneOrFetch("ticgit.git", "https://github.com/jeffWelling/ticgit.git", true);
 		}
+		FileSettings settings = new FileSettings("distrib/gitblit.properties");
+		GitBlit.self().configureContext(settings);
+		JettyLoginService loginService = new JettyLoginService(new File("distrib/users.properties"));
+		loginService.loadUsers();
+		GitBlit.self().setLoginService(loginService);
 	}
 
 	private void cloneOrFetch(String toFolder, String fromUrl, boolean bare) throws Exception {

--
Gitblit v1.9.1