From 4c112ed7a840c3ecc28322213e01820cec92df20 Mon Sep 17 00:00:00 2001 From: Stephan Merker Date: Mon, 3 Oct 2011 17:40:09 +0200 Subject: Refactoring: put tests into same java package as tested class - fixes #587 - test suite and 3 tests (regex and whitespace perf tests) remain in cgeo.geocaching.test --- tests/src/cgeo/geocaching/SettingsTest.java | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 tests/src/cgeo/geocaching/SettingsTest.java (limited to 'tests/src/cgeo/geocaching/SettingsTest.java') diff --git a/tests/src/cgeo/geocaching/SettingsTest.java b/tests/src/cgeo/geocaching/SettingsTest.java new file mode 100644 index 0000000..49ef596 --- /dev/null +++ b/tests/src/cgeo/geocaching/SettingsTest.java @@ -0,0 +1,27 @@ +package cgeo.geocaching; + +import cgeo.geocaching.Settings; +import cgeo.geocaching.cgeo; + +import android.test.ActivityInstrumentationTestCase2; + +public class SettingsTest extends ActivityInstrumentationTestCase2 { + + public SettingsTest() { + super("cgeo.geocaching", cgeo.class); + } + + @Override + protected void setUp() throws Exception { + super.setUp(); + } + + /** + * access settings. + * this should work fine without an exception (once there was an exception because of the empty map file string) + */ + public void testSettingsException() { + // asserts A OR NOT A, because we don't know what the settings are on any device or emulator + assertTrue(Settings.isValidMapFile() || !Settings.isValidMapFile()); + } +} -- cgit v1.1