Make inner classes static in http code
Static classes are preferrable to keep unwanted dependencies away, and they have one less member field. Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>
This commit is contained in:
parent
3bf96dd04b
commit
6f4cf8daec
|
@ -112,7 +112,7 @@ public void testCreate_Enabled() throws ServiceNotEnabledException,
|
|||
service.access(new R("bob", "1.2.3.4"), db);
|
||||
}
|
||||
|
||||
private final class R extends HttpServletRequestWrapper {
|
||||
private static final class R extends HttpServletRequestWrapper {
|
||||
private final String user;
|
||||
|
||||
private final String host;
|
||||
|
|
|
@ -174,7 +174,7 @@ public void testCreate_Enabled() throws ServiceNotEnabledException,
|
|||
assertNotNull("have ReceivePack", rp);
|
||||
}
|
||||
|
||||
private final class R extends HttpServletRequestWrapper {
|
||||
private static final class R extends HttpServletRequestWrapper {
|
||||
private final String user;
|
||||
|
||||
private final String host;
|
||||
|
|
|
@ -136,7 +136,7 @@ public void testCreate_Enabled() throws ServiceNotEnabledException,
|
|||
assertSame(db, up.getRepository());
|
||||
}
|
||||
|
||||
private final class R extends HttpServletRequestWrapper {
|
||||
private static final class R extends HttpServletRequestWrapper {
|
||||
private final String user;
|
||||
|
||||
private final String host;
|
||||
|
|
Loading…
Reference in New Issue