aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src
diff options
context:
space:
mode:
Diffstat (limited to 'tests/src')
-rw-r--r--tests/src/cgeo/geocaching/connector/gc/GCLoginTest.java29
1 files changed, 29 insertions, 0 deletions
diff --git a/tests/src/cgeo/geocaching/connector/gc/GCLoginTest.java b/tests/src/cgeo/geocaching/connector/gc/GCLoginTest.java
new file mode 100644
index 0000000..b03da4c
--- /dev/null
+++ b/tests/src/cgeo/geocaching/connector/gc/GCLoginTest.java
@@ -0,0 +1,29 @@
+package cgeo.geocaching.connector.gc;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+import cgeo.geocaching.enumerations.StatusCode;
+
+import org.apache.commons.lang3.StringUtils;
+
+import junit.framework.TestCase;
+
+public class GCLoginTest extends TestCase {
+
+ final GCLogin instance = GCLogin.getInstance();
+
+ @Override
+ protected void setUp() throws Exception {
+ super.setUp();
+ assertThat(instance.login()).isEqualTo(StatusCode.NO_ERROR);
+ }
+
+ public void testHomeLocation() {
+ assertThat(StringUtils.isNotBlank(GCLogin.retrieveHomeLocation())).isTrue();
+ }
+
+ public void testAvatar() {
+ assertThat(instance.downloadAvatarAndGetMemberStatus()).isNotNull();
+ }
+
+}