[automerger skipped] Merge "DO NOT MERGE - Migrate remaining cts to androidx.test." into pie-cts-dev
am: 4fb729db4e -s ours
am skip reason: subject contains skip directive
Change-Id: I71b2f3cb44260abea706f86371339237447f076b
diff --git a/tests/cts/hostside/app/Android.mk b/tests/cts/hostside/app/Android.mk
index 6d89e58..c03e70b 100644
--- a/tests/cts/hostside/app/Android.mk
+++ b/tests/cts/hostside/app/Android.mk
@@ -20,7 +20,7 @@
LOCAL_MODULE_TAGS := tests
LOCAL_SDK_VERSION := current
-LOCAL_STATIC_JAVA_LIBRARIES := compatibility-device-util-axt ctstestrunner-axt ub-uiautomator \
+LOCAL_STATIC_JAVA_LIBRARIES := compatibility-device-util ctstestrunner ub-uiautomator \
CtsHostsideNetworkTestsAidl
LOCAL_JAVA_LIBRARIES := android.test.runner.stubs android.test.base.stubs
diff --git a/tests/cts/hostside/app/AndroidManifest.xml b/tests/cts/hostside/app/AndroidManifest.xml
index ba0e242..2553f47 100644
--- a/tests/cts/hostside/app/AndroidManifest.xml
+++ b/tests/cts/hostside/app/AndroidManifest.xml
@@ -45,7 +45,7 @@
</application>
<instrumentation
- android:name="androidx.test.runner.AndroidJUnitRunner"
+ android:name="android.support.test.runner.AndroidJUnitRunner"
android:targetPackage="com.android.cts.net.hostside" />
</manifest>
diff --git a/tests/cts/hostside/src/com/android/cts/net/HostsideNetworkTestCase.java b/tests/cts/hostside/src/com/android/cts/net/HostsideNetworkTestCase.java
index a2443b3..7c9ce8f 100644
--- a/tests/cts/hostside/src/com/android/cts/net/HostsideNetworkTestCase.java
+++ b/tests/cts/hostside/src/com/android/cts/net/HostsideNetworkTestCase.java
@@ -128,7 +128,7 @@
protected void runDeviceTests(String packageName, String testClassName, String methodName)
throws DeviceNotAvailableException {
RemoteAndroidTestRunner testRunner = new RemoteAndroidTestRunner(packageName,
- "androidx.test.runner.AndroidJUnitRunner", getDevice().getIDevice());
+ "android.support.test.runner.AndroidJUnitRunner", getDevice().getIDevice());
if (testClassName != null) {
if (methodName != null) {
diff --git a/tests/cts/net/Android.mk b/tests/cts/net/Android.mk
index 45941a7..1430071 100644
--- a/tests/cts/net/Android.mk
+++ b/tests/cts/net/Android.mk
@@ -41,8 +41,8 @@
LOCAL_STATIC_JAVA_LIBRARIES := \
core-tests-support \
- compatibility-device-util-axt \
- ctstestrunner-axt \
+ compatibility-device-util \
+ ctstestrunner \
ctstestserver \
mockwebserver \
junit \
diff --git a/tests/cts/net/AndroidManifest.xml b/tests/cts/net/AndroidManifest.xml
index b261b39..0bfb650 100644
--- a/tests/cts/net/AndroidManifest.xml
+++ b/tests/cts/net/AndroidManifest.xml
@@ -42,7 +42,7 @@
</receiver>
</application>
- <instrumentation android:name="androidx.test.runner.AndroidJUnitRunner"
+ <instrumentation android:name="android.support.test.runner.AndroidJUnitRunner"
android:targetPackage="android.net.cts"
android:label="CTS tests of android.net">
<meta-data android:name="listener"
diff --git a/tests/cts/net/src/android/net/cts/ConnectivityManagerTest.java b/tests/cts/net/src/android/net/cts/ConnectivityManagerTest.java
index 810b5df..441bee3 100644
--- a/tests/cts/net/src/android/net/cts/ConnectivityManagerTest.java
+++ b/tests/cts/net/src/android/net/cts/ConnectivityManagerTest.java
@@ -24,7 +24,6 @@
import static android.net.NetworkCapabilities.TRANSPORT_CELLULAR;
import static android.net.NetworkCapabilities.TRANSPORT_WIFI;
import static android.provider.Settings.Global.NETWORK_METERED_MULTIPATH_PREFERENCE;
-
import static com.android.compatibility.common.util.SystemUtil.runShellCommand;
import android.app.Instrumentation;
@@ -51,30 +50,28 @@
import android.os.SystemClock;
import android.os.SystemProperties;
import android.provider.Settings;
+import android.support.test.InstrumentationRegistry;
import android.system.Os;
import android.system.OsConstants;
import android.test.AndroidTestCase;
import android.text.TextUtils;
import android.util.Log;
-import androidx.test.InstrumentationRegistry;
-
import com.android.internal.R;
import com.android.internal.telephony.PhoneConstants;
-import libcore.io.Streams;
-
import java.io.File;
import java.io.FileNotFoundException;
-import java.io.IOException;
import java.io.InputStream;
+import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;
+import java.lang.NumberFormatException;
import java.net.HttpURLConnection;
import java.net.Inet6Address;
import java.net.InetAddress;
-import java.net.InetSocketAddress;
import java.net.Socket;
+import java.net.InetSocketAddress;
import java.net.URL;
import java.net.UnknownHostException;
import java.nio.charset.StandardCharsets;
@@ -86,6 +83,7 @@
import java.util.concurrent.TimeUnit;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import libcore.io.Streams;
public class ConnectivityManagerTest extends AndroidTestCase {
diff --git a/tests/cts/net/src/android/net/cts/MacAddressTest.java b/tests/cts/net/src/android/net/cts/MacAddressTest.java
index af1e760..ace1cde 100644
--- a/tests/cts/net/src/android/net/cts/MacAddressTest.java
+++ b/tests/cts/net/src/android/net/cts/MacAddressTest.java
@@ -19,13 +19,11 @@
import static android.net.MacAddress.TYPE_BROADCAST;
import static android.net.MacAddress.TYPE_MULTICAST;
import static android.net.MacAddress.TYPE_UNICAST;
-
import static org.junit.Assert.fail;
import android.net.MacAddress;
-
-import androidx.test.filters.SmallTest;
-import androidx.test.runner.AndroidJUnit4;
+import android.support.test.filters.SmallTest;
+import android.support.test.runner.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
diff --git a/tests/cts/net/src/android/net/cts/NetworkWatchlistTest.java b/tests/cts/net/src/android/net/cts/NetworkWatchlistTest.java
index e0c03a1..e85de2a 100644
--- a/tests/cts/net/src/android/net/cts/NetworkWatchlistTest.java
+++ b/tests/cts/net/src/android/net/cts/NetworkWatchlistTest.java
@@ -24,10 +24,9 @@
import android.content.Context;
import android.net.ConnectivityManager;
import android.os.FileUtils;
-
-import androidx.test.InstrumentationRegistry;
-import androidx.test.filters.SmallTest;
-import androidx.test.runner.AndroidJUnit4;
+import android.support.test.filters.SmallTest;
+import android.support.test.runner.AndroidJUnit4;
+import android.support.test.InstrumentationRegistry;
import com.android.compatibility.common.util.ApiLevelUtil;
import com.android.compatibility.common.util.SystemUtil;
@@ -38,6 +37,7 @@
import org.junit.Test;
import org.junit.runner.RunWith;
+
import java.io.File;
import java.io.IOException;
import java.io.InputStream;