Merge "Add SmallTest for presubmit"

This commit is contained in:
TreeHugger Robot
2017-05-22 19:30:27 +00:00
committed by Android (Google) Code Review
4 changed files with 9 additions and 1 deletions

View File

@@ -55,6 +55,7 @@ import android.os.UserHandle;
import android.provider.Settings.Secure;
import android.service.notification.NotificationListenerService;
import android.service.notification.StatusBarNotification;
import android.test.suitebuilder.annotation.SmallTest;
import android.testing.AndroidTestingRunner;
import android.testing.TestableLooper;
import android.testing.TestableLooper.RunWithLooper;
@@ -73,6 +74,7 @@ import org.mockito.MockitoAnnotations;
import com.android.server.lights.Light;
import com.android.server.lights.LightsManager;
@SmallTest
@RunWith(AndroidTestingRunner.class)
@RunWithLooper
public class NotificationManagerServiceTest extends NotificationTestCase {

View File

@@ -31,9 +31,11 @@ import org.junit.runner.RunWith;
import android.os.Handler;
import android.os.Looper;
import android.os.Message;
import android.test.suitebuilder.annotation.SmallTest;
import android.testing.TestableLooper.MessageHandler;
import android.testing.TestableLooper.RunWithLooper;
@SmallTest
@RunWith(AndroidTestingRunner.class)
@RunWithLooper
public class TestableLooperTest {

View File

@@ -22,6 +22,7 @@ import static org.junit.Assert.fail;
import android.content.res.Resources;
import android.support.test.InstrumentationRegistry;
import android.test.suitebuilder.annotation.SmallTest;
import com.android.testables.R;
@@ -29,6 +30,7 @@ import org.junit.Rule;
import org.junit.Test;
import org.junit.runner.RunWith;
@SmallTest
@RunWith(AndroidTestingRunner.class)
public class TestableResourcesTest {
@@ -90,4 +92,4 @@ public class TestableResourcesTest {
assertNull(mContext.getString(existentId));
}
}
}

View File

@@ -20,6 +20,7 @@ import android.provider.Settings.Global;
import android.provider.Settings.Secure;
import android.support.test.InstrumentationRegistry;
import android.support.test.runner.AndroidJUnit4;
import android.test.suitebuilder.annotation.SmallTest;
import org.junit.Before;
import org.junit.Rule;
import org.junit.Test;
@@ -27,6 +28,7 @@ import org.junit.runner.RunWith;
import static org.junit.Assert.*;
@SmallTest
@RunWith(AndroidJUnit4.class)
public class TestableSettingsProviderTest {