From 134a895dbf6db6b9784f165a3a577d6059949169 Mon Sep 17 00:00:00 2001
From: Mohamed MOUNIROU <mmounirou@MacBook-Pro-de-Mohamed.local>
Date: Tue, 04 Oct 2011 16:35:09 -0400
Subject: [PATCH] add tools to install giblet as service on linux based os
---
tests/com/gitblit/tests/FederationTests.java | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/tests/com/gitblit/tests/FederationTests.java b/tests/com/gitblit/tests/FederationTests.java
index 28b089f..c5f7e8d 100644
--- a/tests/com/gitblit/tests/FederationTests.java
+++ b/tests/com/gitblit/tests/FederationTests.java
@@ -24,6 +24,7 @@
import junit.framework.TestCase;
import com.gitblit.Constants.AccessRestrictionType;
+import com.gitblit.Constants.FederationProposalResult;
import com.gitblit.Constants.FederationRequest;
import com.gitblit.Constants.FederationToken;
import com.gitblit.FederationServlet;
@@ -91,14 +92,15 @@
"testtoken", repositories);
// propose federation
- assertTrue("proposal refused",
- FederationUtils.propose("http://localhost:" + port, proposal));
+ assertEquals("proposal refused",
+ FederationUtils.propose("http://localhost:" + port, proposal),
+ FederationProposalResult.NO_PROPOSALS);
}
public void testPullRepositories() throws Exception {
try {
- String url = FederationServlet.asFederationLink("http://localhost:" + port, "testtoken",
- FederationRequest.PULL_REPOSITORIES);
+ String url = FederationServlet.asFederationLink("http://localhost:" + port,
+ "testtoken", FederationRequest.PULL_REPOSITORIES);
String json = FederationUtils.readJson(url);
} catch (IOException e) {
if (!e.getMessage().contains("403")) {
--
Gitblit v1.9.1