summaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.http.test
diff options
context:
space:
mode:
authorHan-Wen Nienhuys <hanwen@google.com>2018-05-16 16:34:16 +0200
committerMatthias Sohn <matthias.sohn@sap.com>2018-05-18 17:59:45 +0200
commitf3ec7cf3f0436a79e252251a31dbc62694555897 (patch)
tree49a647fa520bb5a1016425df26357947f8dab95c /org.eclipse.jgit.http.test
parent667e30678a6bad26f4d4d412e996b293e52e5b87 (diff)
downloadjgit-f3ec7cf3f0436a79e252251a31dbc62694555897.tar.gz
jgit-f3ec7cf3f0436a79e252251a31dbc62694555897.zip
Remove further unnecessary 'final' keywords
Remove it from * package private functions. * try blocks * for loops this was done with the following python script: $ cat f.py import sys import re import os def replaceFinal(m): return m.group(1) + "(" + m.group(2).replace('final ', '') + ")" methodDecl = re.compile(r"^([\t ]*[a-zA-Z_ ]+)\(([^)]*)\)") def subst(fn): input = open(fn) os.rename(fn, fn + "~") dest = open(fn, 'w') for l in input: l = methodDecl.sub(replaceFinal, l) dest.write(l) dest.close() for root, dirs, files in os.walk(".", topdown=False): for f in files: if not f.endswith('.java'): continue full = os.path.join(root, f) print full subst(full) Change-Id: If533a75a417594fc893e7c669d2c1f0f6caeb7ca Signed-off-by: Han-Wen Nienhuys <hanwen@google.com>
Diffstat (limited to 'org.eclipse.jgit.http.test')
-rw-r--r--org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/AsIsServiceTest.java2
-rw-r--r--org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultReceivePackFactoryTest.java2
-rw-r--r--org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultUploadPackFactoryTest.java2
3 files changed, 3 insertions, 3 deletions
diff --git a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/AsIsServiceTest.java b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/AsIsServiceTest.java
index e94a792ff2..298bf2170c 100644
--- a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/AsIsServiceTest.java
+++ b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/AsIsServiceTest.java
@@ -133,7 +133,7 @@ public class AsIsServiceTest extends LocalDiskRepositoryTestCase {
private final String host;
- R(final String user, final String host) {
+ R(String user, String host) {
super(new Request(null, null) /* can't pass null, sigh */);
this.user = user;
this.host = host;
diff --git a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultReceivePackFactoryTest.java b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultReceivePackFactoryTest.java
index b24e2dfc7b..ade1e1d2be 100644
--- a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultReceivePackFactoryTest.java
+++ b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultReceivePackFactoryTest.java
@@ -205,7 +205,7 @@ public class DefaultReceivePackFactoryTest extends LocalDiskRepositoryTestCase {
private final String host;
- R(final String user, final String host) {
+ R(String user, String host) {
super(new Request(null, null) /* can't pass null, sigh */);
this.user = user;
this.host = host;
diff --git a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultUploadPackFactoryTest.java b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultUploadPackFactoryTest.java
index ce24d64b7b..268c281e29 100644
--- a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultUploadPackFactoryTest.java
+++ b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/DefaultUploadPackFactoryTest.java
@@ -161,7 +161,7 @@ public class DefaultUploadPackFactoryTest extends LocalDiskRepositoryTestCase {
private final String host;
- R(final String user, final String host) {
+ R(String user, String host) {
super(new Request(null, null) /* can't pass null, sigh */);
this.user = user;
this.host = host;