diff options
Diffstat (limited to 'tests/src/cgeo/geocaching/activity/ProgressTest.java')
| -rw-r--r-- | tests/src/cgeo/geocaching/activity/ProgressTest.java | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tests/src/cgeo/geocaching/activity/ProgressTest.java b/tests/src/cgeo/geocaching/activity/ProgressTest.java index 9dab166..db2b9d9 100644 --- a/tests/src/cgeo/geocaching/activity/ProgressTest.java +++ b/tests/src/cgeo/geocaching/activity/ProgressTest.java @@ -1,5 +1,7 @@ package cgeo.geocaching.activity; +import static org.assertj.core.api.Assertions.assertThat; + import cgeo.geocaching.AboutActivity; import android.annotation.TargetApi; @@ -7,7 +9,7 @@ import android.test.ActivityInstrumentationTestCase2; /** * This test uses the about activity to avoid side effects like network and GPS being triggered by the main activity. - * + * */ @TargetApi(8) public class ProgressTest extends ActivityInstrumentationTestCase2<AboutActivity> { @@ -18,17 +20,17 @@ public class ProgressTest extends ActivityInstrumentationTestCase2<AboutActivity public void testProgressWrapper() { final Progress progress = new Progress(); - assertFalse(progress.isShowing()); // nothing shown initially + assertThat(progress.isShowing()).isFalse(); // nothing shown initially progress.show(getActivity(), "Title", "Message", true, null); - assertTrue(progress.isShowing()); + assertThat(progress.isShowing()).isTrue(); progress.setMessage("Test"); - assertTrue(progress.isShowing()); + assertThat(progress.isShowing()).isTrue(); for (int i = 0; i < 2; i++) { // fault tolerant when dismissing to often progress.dismiss(); - assertFalse(progress.isShowing()); + assertThat(progress.isShowing()).isFalse(); } } } |
