summaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.http.test
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.jgit.http.test')
-rw-r--r--org.eclipse.jgit.http.test/META-INF/MANIFEST.MF45
-rw-r--r--org.eclipse.jgit.http.test/pom.xml2
-rw-r--r--org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/RefsUnreadableInMemoryRepository.java8
-rw-r--r--org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/TestRepositoryResolver.java9
-rw-r--r--org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/SmartClientSmartServerTest.java4
5 files changed, 36 insertions, 32 deletions
diff --git a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF
index 58f21b5256..06a6f8db28 100644
--- a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF
+++ b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %plugin_name
Bundle-SymbolicName: org.eclipse.jgit.http.test
-Bundle-Version: 4.9.3.qualifier
+Bundle-Version: 4.10.0.qualifier
Bundle-Vendor: %provider_name
Bundle-Localization: plugin
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
@@ -24,25 +24,26 @@ Import-Package: javax.servlet;version="[2.5.0,3.2.0)",
org.eclipse.jetty.util.log;version="[9.4.5,10.0.0)",
org.eclipse.jetty.util.security;version="[9.4.5,10.0.0)",
org.eclipse.jetty.util.thread;version="[9.4.5,10.0.0)",
- org.eclipse.jgit.errors;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.http.server;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.http.server.glue;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.http.server.resolver;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.internal;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.internal.storage.dfs;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.internal.storage.file;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.junit;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.junit.http;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.lib;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.nls;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.revwalk;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.storage.file;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.transport;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.transport.http;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.transport.http.apache;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.transport.resolver;version="[4.9.3,4.10.0)",
- org.eclipse.jgit.util;version="[4.9.3,4.10.0)",
+ org.eclipse.jgit.errors;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.http.server;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.http.server.glue;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.http.server.resolver;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.internal;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.internal.storage.dfs;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.internal.storage.file;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.internal.storage.reftable;version="[4.9.0,4.11.0)",
+ org.eclipse.jgit.junit;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.junit.http;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.lib;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.nls;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.revwalk;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.storage.file;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.transport;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.transport.http;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.transport.http.apache;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.transport.resolver;version="[4.10.0,4.11.0)",
+ org.eclipse.jgit.util;version="[4.10.0,4.11.0)",
org.hamcrest.core;version="[1.1.0,2.0.0)",
- org.junit;version="[4.0.0,5.0.0)",
- org.junit.runner;version="[4.0.0,5.0.0)",
- org.junit.runners;version="[4.0.0,5.0.0)"
+ org.junit;version="[4.12,5.0.0)",
+ org.junit.runner;version="[4.12,5.0.0)",
+ org.junit.runners;version="[4.12,5.0.0)"
diff --git a/org.eclipse.jgit.http.test/pom.xml b/org.eclipse.jgit.http.test/pom.xml
index 72cfacdd80..fc702d0688 100644
--- a/org.eclipse.jgit.http.test/pom.xml
+++ b/org.eclipse.jgit.http.test/pom.xml
@@ -51,7 +51,7 @@
<parent>
<groupId>org.eclipse.jgit</groupId>
<artifactId>org.eclipse.jgit-parent</artifactId>
- <version>4.9.3-SNAPSHOT</version>
+ <version>4.10.0-SNAPSHOT</version>
</parent>
<artifactId>org.eclipse.jgit.http.test</artifactId>
diff --git a/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/RefsUnreadableInMemoryRepository.java b/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/RefsUnreadableInMemoryRepository.java
index a1e41d12d5..78f909eeac 100644
--- a/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/RefsUnreadableInMemoryRepository.java
+++ b/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/RefsUnreadableInMemoryRepository.java
@@ -46,6 +46,7 @@ import java.io.IOException;
import org.eclipse.jgit.internal.storage.dfs.DfsRepositoryDescription;
import org.eclipse.jgit.internal.storage.dfs.InMemoryRepository;
+import org.eclipse.jgit.internal.storage.reftable.Reftable;
import org.eclipse.jgit.lib.RefDatabase;
/**
@@ -64,6 +65,7 @@ class RefsUnreadableInMemoryRepository extends InMemoryRepository {
failing = false;
}
+ /** {@inheritDoc} */
@Override
public RefDatabase getRefDatabase() {
return refs;
@@ -80,14 +82,12 @@ class RefsUnreadableInMemoryRepository extends InMemoryRepository {
}
private class RefsUnreadableRefDatabase extends MemRefDatabase {
-
@Override
- protected RefCache scanAllRefs() throws IOException {
+ protected Reftable reader() throws IOException {
if (failing) {
throw new IOException("disk failed, no refs found");
- } else {
- return super.scanAllRefs();
}
+ return super.reader();
}
}
}
diff --git a/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/TestRepositoryResolver.java b/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/TestRepositoryResolver.java
index 334e57c6d1..c6a3e3b8d0 100644
--- a/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/TestRepositoryResolver.java
+++ b/org.eclipse.jgit.http.test/src/org/eclipse/jgit/http/test/TestRepositoryResolver.java
@@ -50,7 +50,9 @@ import org.eclipse.jgit.lib.Repository;
import org.eclipse.jgit.transport.resolver.RepositoryResolver;
import org.eclipse.jgit.transport.resolver.ServiceNotEnabledException;
-/** A simple repository resolver for tests. */
+/**
+ * A simple repository resolver for tests.
+ */
public final class TestRepositoryResolver
implements RepositoryResolver<HttpServletRequest> {
@@ -59,8 +61,8 @@ public final class TestRepositoryResolver
private final String repoName;
/**
- * Creates a new {@link TestRepositoryResolver} that resolves the given name to
- * the given repository.
+ * Create a new {@link org.eclipse.jgit.http.test.TestRepositoryResolver}
+ * that resolves the given name to the given repository.
*
* @param repo
* to resolve to
@@ -72,6 +74,7 @@ public final class TestRepositoryResolver
this.repoName = repoName;
}
+ /** {@inheritDoc} */
@Override
public Repository open(HttpServletRequest req, String name)
throws RepositoryNotFoundException, ServiceNotEnabledException {
diff --git a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/SmartClientSmartServerTest.java b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/SmartClientSmartServerTest.java
index 51b79903c6..5f40be4e05 100644
--- a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/SmartClientSmartServerTest.java
+++ b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/SmartClientSmartServerTest.java
@@ -43,6 +43,7 @@
package org.eclipse.jgit.http.test;
+import static java.nio.charset.StandardCharsets.UTF_8;
import static org.eclipse.jgit.util.HttpSupport.HDR_CONTENT_ENCODING;
import static org.eclipse.jgit.util.HttpSupport.HDR_CONTENT_LENGTH;
import static org.eclipse.jgit.util.HttpSupport.HDR_CONTENT_TYPE;
@@ -56,7 +57,6 @@ import static org.junit.Assert.fail;
import java.io.IOException;
import java.io.PrintWriter;
import java.net.URISyntaxException;
-import java.nio.charset.StandardCharsets;
import java.text.MessageFormat;
import java.util.Arrays;
import java.util.Collection;
@@ -1084,7 +1084,7 @@ public class SmartClientSmartServerTest extends HttpTestCase {
public void testInvalidWant() throws Exception {
@SuppressWarnings("resource")
ObjectId id = new ObjectInserter.Formatter().idFor(Constants.OBJ_BLOB,
- "testInvalidWant".getBytes(StandardCharsets.UTF_8));
+ "testInvalidWant".getBytes(UTF_8));
Repository dst = createBareRepository();
try (Transport t = Transport.open(dst, remoteURI);