Migrate frameworks/base/packages/SettingsProvider/test to androidx.test
See go/jetpack-test-android-migration Test: make checkbuild Change-Id: Ie4e8f36dc8ec8769ccc2a016a1da682adb725966
This commit is contained in:
@@ -10,7 +10,7 @@ LOCAL_SRC_FILES := $(call all-subdir-java-files) \
|
||||
../src/com/android/providers/settings/SettingsState.java \
|
||||
../src/com/android/providers/settings/SettingsHelper.java
|
||||
|
||||
LOCAL_STATIC_JAVA_LIBRARIES := android-support-test
|
||||
LOCAL_STATIC_JAVA_LIBRARIES := androidx.test.rules
|
||||
|
||||
LOCAL_JAVA_LIBRARIES := android.test.base
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
</application>
|
||||
|
||||
<instrumentation
|
||||
android:name="android.support.test.runner.AndroidJUnitRunner"
|
||||
android:name="androidx.test.runner.AndroidJUnitRunner"
|
||||
android:targetPackage="com.android.providers.setting.test"
|
||||
android:label="Settings Provider Tests" />
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
<option name="test-tag" value="SettingsProviderTest" />
|
||||
<test class="com.android.tradefed.testtype.AndroidJUnitTest" >
|
||||
<option name="package" value="com.android.providers.setting.test" />
|
||||
<option name="runner" value="android.support.test.runner.AndroidJUnitRunner" />
|
||||
<option name="runner" value="androidx.test.runner.AndroidJUnitRunner" />
|
||||
<option name="hidden-api-checks" value="false"/>
|
||||
</test>
|
||||
</configuration>
|
||||
|
||||
@@ -25,9 +25,12 @@ import android.net.Uri;
|
||||
import android.os.UserHandle;
|
||||
import android.os.UserManager;
|
||||
import android.provider.Settings;
|
||||
import android.support.test.InstrumentationRegistry;
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
|
||||
import androidx.test.InstrumentationRegistry;
|
||||
import androidx.test.runner.AndroidJUnit4;
|
||||
|
||||
import libcore.io.Streams;
|
||||
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
import java.io.FileInputStream;
|
||||
|
||||
@@ -24,8 +24,9 @@ import android.content.ContentResolver;
|
||||
import android.os.Bundle;
|
||||
import android.provider.DeviceConfig;
|
||||
import android.provider.Settings;
|
||||
import android.support.test.InstrumentationRegistry;
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
|
||||
import androidx.test.InstrumentationRegistry;
|
||||
import androidx.test.runner.AndroidJUnit4;
|
||||
|
||||
import libcore.io.Streams;
|
||||
|
||||
|
||||
@@ -26,10 +26,11 @@ import android.os.Process;
|
||||
import android.os.SystemClock;
|
||||
import android.os.UserManager;
|
||||
import android.provider.Settings;
|
||||
import android.support.test.InstrumentationRegistry;
|
||||
import android.support.test.filters.LargeTest;
|
||||
import android.util.Log;
|
||||
|
||||
import androidx.test.InstrumentationRegistry;
|
||||
import androidx.test.filters.LargeTest;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
@@ -24,8 +24,10 @@ import android.content.Context;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.provider.Settings;
|
||||
import android.support.test.InstrumentationRegistry;
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
|
||||
import androidx.test.InstrumentationRegistry;
|
||||
import androidx.test.runner.AndroidJUnit4;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
@@ -17,19 +17,10 @@
|
||||
package com.android.providers.settings;
|
||||
|
||||
import static junit.framework.Assert.assertEquals;
|
||||
import static junit.framework.Assert.assertSame;
|
||||
import static junit.framework.Assert.assertNull;
|
||||
import static junit.framework.Assert.fail;
|
||||
|
||||
import com.android.internal.app.LocalePicker;
|
||||
import com.android.providers.settings.SettingsHelper;
|
||||
|
||||
import android.os.LocaleList;
|
||||
import android.support.test.runner.AndroidJUnit4;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import androidx.test.runner.AndroidJUnit4;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
Reference in New Issue
Block a user