aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/src/cgeo/geocaching/GCConstantsTest.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/src/cgeo/geocaching/GCConstantsTest.java b/tests/src/cgeo/geocaching/GCConstantsTest.java
index be7b5a8..696273d 100644
--- a/tests/src/cgeo/geocaching/GCConstantsTest.java
+++ b/tests/src/cgeo/geocaching/GCConstantsTest.java
@@ -20,9 +20,10 @@ public class GCConstantsTest extends AndroidTestCase {
public static void testCacheCount() {
assertCacheCount(149, "<strong><img src=\"/images/icons/icon_smile.png\" title=\"Caches Found\" /> 149</strong>");
assertCacheCount(491, MockedCache.readCachePage("GC2CJPF"));
+ assertCacheCount(1510, "<strong><img src=\"/images/icons/icon_smile.png\" title=\"Caches Found\" /> 1,510&nbsp;&middot;&nbsp;<img src=\"/images/challenges/types/sm/challenge.png\" title=\"Challenges Completed\" /> 2</strong>");
}
private static void assertCacheCount(final int count, final String html) {
- assertEquals(count, Integer.valueOf(BaseUtils.getMatch(html, GCConstants.PATTERN_CACHES_FOUND, true, "0")).intValue());
+ assertEquals(count, Integer.parseInt(BaseUtils.getMatch(html, GCConstants.PATTERN_CACHES_FOUND, true, "0").replaceAll(",", "")));
}
}