diff options
| author | Bananeweizen <bananeweizen@gmx.de> | 2013-12-16 16:53:37 +0100 |
|---|---|---|
| committer | Bananeweizen <bananeweizen@gmx.de> | 2013-12-16 16:53:37 +0100 |
| commit | c0ba0ccc74ee1c0a9d1e84a9cf58b30ffff502b3 (patch) | |
| tree | 814a2edb58eaa3f67e4f123b9a3386f58f67e785 /tests/src/cgeo/geocaching/cgeoApplicationTest.java | |
| parent | 3719de7a754c103a3e841ec68ba8af31eda30d76 (diff) | |
| download | cgeo-c0ba0ccc74ee1c0a9d1e84a9cf58b30ffff502b3.zip cgeo-c0ba0ccc74ee1c0a9d1e84a9cf58b30ffff502b3.tar.gz cgeo-c0ba0ccc74ee1c0a9d1e84a9cf58b30ffff502b3.tar.bz2 | |
refactoring: remove duplication in login classes
* convert from static to singletons
Diffstat (limited to 'tests/src/cgeo/geocaching/cgeoApplicationTest.java')
| -rw-r--r-- | tests/src/cgeo/geocaching/cgeoApplicationTest.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/src/cgeo/geocaching/cgeoApplicationTest.java b/tests/src/cgeo/geocaching/cgeoApplicationTest.java index 960ddb6..c4737db 100644 --- a/tests/src/cgeo/geocaching/cgeoApplicationTest.java +++ b/tests/src/cgeo/geocaching/cgeoApplicationTest.java @@ -2,8 +2,8 @@ package cgeo.geocaching; import cgeo.CGeoTestCase; import cgeo.geocaching.connector.ConnectorFactory; -import cgeo.geocaching.connector.gc.GCParser; import cgeo.geocaching.connector.gc.GCLogin; +import cgeo.geocaching.connector.gc.GCParser; import cgeo.geocaching.connector.gc.Tile; import cgeo.geocaching.enumerations.CacheType; import cgeo.geocaching.enumerations.LiveMapStrategy.Strategy; @@ -51,7 +51,7 @@ public class cgeoApplicationTest extends CGeoTestCase { @SuppressWarnings("static-method") @SmallTest public void testPreconditions() { - assertEquals(StatusCode.NO_ERROR, GCLogin.login()); + assertEquals(StatusCode.NO_ERROR, GCLogin.getInstance().login()); } /** @@ -143,7 +143,7 @@ public class cgeoApplicationTest extends CGeoTestCase { // restore user and password TestSettings.setLogin(login.left, login.right); Settings.setMemberStatus(memberStatus); - GCLogin.login(); + GCLogin.getInstance().login(); } } @@ -417,7 +417,7 @@ public class cgeoApplicationTest extends CGeoTestCase { private static void deleteCacheFromDBAndLogout(String geocode) { deleteCacheFromDB(geocode); - GCLogin.logout(); + GCLogin.getInstance().logout(); // Modify login data to avoid an automatic login again TestSettings.setLogin("c:geo", "c:geo"); Settings.setMemberStatus("Basic member"); |
