mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-07 09:38:52 -06:00
Annotate all Android tests
This commit is contained in:
@@ -20,7 +20,6 @@
|
||||
package org.isoron.uhabits;
|
||||
|
||||
import android.content.*;
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.uiautomator.*;
|
||||
|
||||
import com.linkedin.android.testbutler.*;
|
||||
@@ -36,7 +35,6 @@ import java.io.*;
|
||||
import static android.support.test.InstrumentationRegistry.*;
|
||||
import static android.support.test.uiautomator.UiDevice.*;
|
||||
|
||||
@LargeTest
|
||||
public class BaseUIAutomatorTest
|
||||
{
|
||||
private static final String PKG = "org.isoron.uhabits";
|
||||
|
||||
@@ -19,13 +19,19 @@
|
||||
|
||||
package org.isoron.uhabits.acceptance;
|
||||
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.runner.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
import static org.isoron.uhabits.acceptance.steps.CommonSteps.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.*;
|
||||
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@LargeTest
|
||||
public class AboutTest extends BaseUIAutomatorTest
|
||||
{
|
||||
@Test
|
||||
|
||||
@@ -19,14 +19,20 @@
|
||||
|
||||
package org.isoron.uhabits.acceptance;
|
||||
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.runner.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
import static org.isoron.uhabits.acceptance.steps.CommonSteps.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.EditHabitSteps.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.*;
|
||||
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@LargeTest
|
||||
public class HabitsTest extends BaseUIAutomatorTest
|
||||
{
|
||||
@Test
|
||||
|
||||
@@ -19,15 +19,19 @@
|
||||
|
||||
package org.isoron.uhabits.acceptance;
|
||||
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.runner.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
import static org.isoron.uhabits.acceptance.steps.CommonSteps.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.*;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.ABOUT;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.HELP;
|
||||
import static org.isoron.uhabits.acceptance.steps.ListHabitsSteps.MenuItem.SETTINGS;
|
||||
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@LargeTest
|
||||
public class LinksTest extends BaseUIAutomatorTest
|
||||
{
|
||||
@Test
|
||||
|
||||
@@ -20,14 +20,17 @@
|
||||
package org.isoron.uhabits.integration;
|
||||
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.runner.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.isoron.uhabits.activities.about.*;
|
||||
import org.isoron.uhabits.activities.habits.list.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
import static java.lang.Thread.*;
|
||||
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@LargeTest
|
||||
public class SavedStateTest extends BaseUIAutomatorTest
|
||||
{
|
||||
|
||||
@@ -36,7 +36,6 @@ import static org.hamcrest.MatcherAssert.*;
|
||||
import static org.hamcrest.core.IsEqual.equalTo;
|
||||
import static org.isoron.uhabits.core.models.HabitList.Order.*;
|
||||
|
||||
@SuppressWarnings("JavaDoc")
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@MediumTest
|
||||
public class HabitListTest extends BaseAndroidTest
|
||||
|
||||
@@ -20,12 +20,15 @@
|
||||
package org.isoron.uhabits.performance;
|
||||
|
||||
import android.support.test.filters.*;
|
||||
import android.support.test.runner.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.isoron.uhabits.core.models.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
@MediumTest
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@LargeTest
|
||||
public class PerformanceTest extends BaseAndroidTest
|
||||
{
|
||||
private Habit habit;
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
package org.isoron.uhabits.utils;
|
||||
|
||||
import android.app.*;
|
||||
import android.support.test.runner.*;
|
||||
import android.test.suitebuilder.annotation.*;
|
||||
|
||||
import org.isoron.uhabits.*;
|
||||
import org.isoron.uhabits.core.commands.*;
|
||||
@@ -27,12 +29,15 @@ import org.isoron.uhabits.core.models.*;
|
||||
import org.isoron.uhabits.core.utils.*;
|
||||
import org.isoron.uhabits.intents.*;
|
||||
import org.junit.*;
|
||||
import org.junit.runner.*;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
import static java.util.Arrays.asList;
|
||||
import static java.util.Arrays.*;
|
||||
import static org.mockito.Mockito.*;
|
||||
|
||||
@RunWith(AndroidJUnit4.class)
|
||||
@MediumTest
|
||||
public class ReminderSchedulerTest extends BaseAndroidTest
|
||||
{
|
||||
private Habit habit;
|
||||
@@ -96,6 +101,7 @@ public class ReminderSchedulerTest extends BaseAndroidTest
|
||||
long now = timestamp(2015, 1, 26, 13, 0);
|
||||
DateUtils.setFixedLocalTime(now);
|
||||
|
||||
fixtures.purgeHabits(habitList);
|
||||
Habit h1 = fixtures.createEmptyHabit();
|
||||
Habit h2 = fixtures.createEmptyHabit();
|
||||
Habit h3 = fixtures.createEmptyHabit();
|
||||
|
||||
@@ -63,7 +63,7 @@ public class HabitsApplication extends Application
|
||||
{
|
||||
try
|
||||
{
|
||||
Class.forName ("org.isoron.uhabits.BaseAndroidTest");
|
||||
Class.forName("org.isoron.uhabits.BaseAndroidTest");
|
||||
return true;
|
||||
}
|
||||
catch (final ClassNotFoundException e)
|
||||
|
||||
Reference in New Issue
Block a user