diff options
Diffstat (limited to 'tests/src/cgeo/geocaching/geopoint/GeopointTest.java')
| -rw-r--r-- | tests/src/cgeo/geocaching/geopoint/GeopointTest.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/src/cgeo/geocaching/geopoint/GeopointTest.java b/tests/src/cgeo/geocaching/geopoint/GeopointTest.java index 7ce39b7..8bb0956 100644 --- a/tests/src/cgeo/geocaching/geopoint/GeopointTest.java +++ b/tests/src/cgeo/geocaching/geopoint/GeopointTest.java @@ -4,6 +4,7 @@ import cgeo.geocaching.geopoint.Geopoint.DDD; import cgeo.geocaching.geopoint.Geopoint.DMM; import cgeo.geocaching.geopoint.Geopoint.DMS; +import android.os.Bundle; import android.test.AndroidTestCase; import junit.framework.Assert; @@ -61,6 +62,14 @@ public class GeopointTest extends AndroidTestCase { Assert.assertEquals(107.715, gp2.bearingTo(gp1), 1e-3); } + public static void testParcelable() { + final Geopoint gp = new Geopoint(1.2, 3.4); + final String KEY = "geopoint"; + final Bundle bundle = new Bundle(); + bundle.putParcelable(KEY, gp); + assertEquals(gp, bundle.getParcelable(KEY)); + } + public static void testDDD() { // case 1 final Geopoint gp1 = new Geopoint(51.3d, 13.8d); |
