summaryrefslogtreecommitdiffstats
path: root/tools/emulator
diff options
context:
space:
mode:
authorSteve Moyer <smoyer@google.com>2014-02-12 16:03:45 -0800
committerEvan Charlton <evanc@google.com>2014-03-03 15:28:02 -0800
commitb99f97d38ec986e90b15ea96961cf0f9f911ba93 (patch)
tree9b9d8b0a095a4d346cf97e1dafda7ef4fb985950 /tools/emulator
parent4a64e0a01523752115af757dad8f020cb92e34c8 (diff)
downloadandroid_development-b99f97d38ec986e90b15ea96961cf0f9f911ba93.tar.gz
android_development-b99f97d38ec986e90b15ea96961cf0f9f911ba93.tar.bz2
android_development-b99f97d38ec986e90b15ea96961cf0f9f911ba93.zip
Merging emulator smoke test projects
Combining SmsTest, GpsLocationTests, and ConnectivityTest Change-Id: I7a9b8e787af37704e6af43b93f169ef90980cb2d
Diffstat (limited to 'tools/emulator')
-rw-r--r--tools/emulator/test-apps/ConnectivityTest/Android.mk32
-rw-r--r--tools/emulator/test-apps/ConnectivityTest/AndroidManifest.xml27
-rw-r--r--tools/emulator/test-apps/GpsLocationTest/Android.mk32
-rw-r--r--tools/emulator/test-apps/GpsLocationTest/AndroidManifest.xml27
-rw-r--r--tools/emulator/test-apps/SmokeTests/Android.mk (renamed from tools/emulator/test-apps/SmsTest/Android.mk)2
-rw-r--r--tools/emulator/test-apps/SmokeTests/AndroidManifest.xml (renamed from tools/emulator/test-apps/SmsTest/AndroidManifest.xml)9
-rw-r--r--tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/connectivity/ConnectivityTest.java (renamed from tools/emulator/test-apps/ConnectivityTest/src/com/android/emulator/connectivity/test/ConnectivityTest.java)2
-rw-r--r--tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/gps/GpsLocationTest.java (renamed from tools/emulator/test-apps/GpsLocationTest/src/com/android/emulator/gps/test/GpsLocationTest.java)2
-rw-r--r--tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/sms/SmsTest.java (renamed from tools/emulator/test-apps/SmsTest/src/com/android/emulator/sms/test/SmsTest.java)4
9 files changed, 12 insertions, 125 deletions
diff --git a/tools/emulator/test-apps/ConnectivityTest/Android.mk b/tools/emulator/test-apps/ConnectivityTest/Android.mk
deleted file mode 100644
index ca20d574a..000000000
--- a/tools/emulator/test-apps/ConnectivityTest/Android.mk
+++ /dev/null
@@ -1,32 +0,0 @@
-# Copyright (C) 2011 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := optional
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := ConnectivityTest
-
-LOCAL_SDK_VERSION := 4
-
-LOCAL_PROGUARD_ENABLED := disabled
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/tools/emulator/test-apps/ConnectivityTest/AndroidManifest.xml b/tools/emulator/test-apps/ConnectivityTest/AndroidManifest.xml
deleted file mode 100644
index 80f65cf80..000000000
--- a/tools/emulator/test-apps/ConnectivityTest/AndroidManifest.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2011 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
- package="com.android.emulator.connectivity.test"
- android:versionCode="1"
- android:versionName="1.0">
- <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
- <uses-permission android:name="android.permission.INTERNET" />
- <uses-sdk android:minSdkVersion="4" />
- <instrumentation android:targetPackage="com.android.emulator.connectivity.test" android:name="android.test.InstrumentationTestRunner" />
- <application android:label="Connectivity Test">
- <uses-library android:name="android.test.runner" />
- </application>
-</manifest> \ No newline at end of file
diff --git a/tools/emulator/test-apps/GpsLocationTest/Android.mk b/tools/emulator/test-apps/GpsLocationTest/Android.mk
deleted file mode 100644
index 5f90f3a5b..000000000
--- a/tools/emulator/test-apps/GpsLocationTest/Android.mk
+++ /dev/null
@@ -1,32 +0,0 @@
-# Copyright (C) 2011 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := optional
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := GpsLocationTest
-
-LOCAL_SDK_VERSION := 4
-
-LOCAL_PROGUARD_ENABLED := disabled
-
-include $(BUILD_PACKAGE)
-
-# Use the following include to make our test apk.
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/tools/emulator/test-apps/GpsLocationTest/AndroidManifest.xml b/tools/emulator/test-apps/GpsLocationTest/AndroidManifest.xml
deleted file mode 100644
index 901855e8a..000000000
--- a/tools/emulator/test-apps/GpsLocationTest/AndroidManifest.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2011 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
- package="com.android.emulator.gps.test"
- android:versionCode="1"
- android:versionName="1.0">
- <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
- <uses-sdk android:minSdkVersion="4" />
- <instrumentation android:targetPackage="com.android.emulator.gps.test"
- android:name="android.test.InstrumentationTestRunner" />
- <application android:label="GPS Location Test">
- <uses-library android:name="android.test.runner" />
- </application>
-</manifest> \ No newline at end of file
diff --git a/tools/emulator/test-apps/SmsTest/Android.mk b/tools/emulator/test-apps/SmokeTests/Android.mk
index 9a5411ab3..ccd3eb45d 100644
--- a/tools/emulator/test-apps/SmsTest/Android.mk
+++ b/tools/emulator/test-apps/SmokeTests/Android.mk
@@ -22,7 +22,7 @@ LOCAL_MODULE_TAGS := optional
# Only compile source java files in this apk.
LOCAL_SRC_FILES := $(call all-java-files-under, src)
-LOCAL_PACKAGE_NAME := SmsTest
+LOCAL_PACKAGE_NAME := EmulatorSmokeTests
LOCAL_SDK_VERSION := 4
diff --git a/tools/emulator/test-apps/SmsTest/AndroidManifest.xml b/tools/emulator/test-apps/SmokeTests/AndroidManifest.xml
index 2819b6e6f..8843a00c9 100644
--- a/tools/emulator/test-apps/SmsTest/AndroidManifest.xml
+++ b/tools/emulator/test-apps/SmokeTests/AndroidManifest.xml
@@ -14,11 +14,14 @@
limitations under the License.
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
- package="com.android.emulator.sms.test">
+ package="com.android.emulator.smoketests">
+ <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
+ <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
+ <uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_SMS" />
<uses-sdk android:minSdkVersion="4" />
- <instrumentation android:targetPackage="com.android.emulator.sms.test"
+ <instrumentation android:targetPackage="com.android.emulator.smoketests"
android:name="android.support.test.runner.AndroidJUnitRunner" />
- <application android:label="Sms Test">
+ <application android:label="Emulator Smoke Tests">
</application>
</manifest>
diff --git a/tools/emulator/test-apps/ConnectivityTest/src/com/android/emulator/connectivity/test/ConnectivityTest.java b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/connectivity/ConnectivityTest.java
index 9931eb849..9fe1ebe77 100644
--- a/tools/emulator/test-apps/ConnectivityTest/src/com/android/emulator/connectivity/test/ConnectivityTest.java
+++ b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/connectivity/ConnectivityTest.java
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.android.emulator.connectivity.test;
+package com.android.emulator.smoketests.connectivity;
import java.io.IOException;
import java.net.URL;
diff --git a/tools/emulator/test-apps/GpsLocationTest/src/com/android/emulator/gps/test/GpsLocationTest.java b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/gps/GpsLocationTest.java
index 6eb38349a..1e0258c29 100644
--- a/tools/emulator/test-apps/GpsLocationTest/src/com/android/emulator/gps/test/GpsLocationTest.java
+++ b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/gps/GpsLocationTest.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.android.emulator.gps.test;
+package com.android.emulator.smoketests.gps;
import android.content.Context;
import android.location.Location;
diff --git a/tools/emulator/test-apps/SmsTest/src/com/android/emulator/sms/test/SmsTest.java b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/sms/SmsTest.java
index 13bcf7fca..2e18cc4bc 100644
--- a/tools/emulator/test-apps/SmsTest/src/com/android/emulator/sms/test/SmsTest.java
+++ b/tools/emulator/test-apps/SmokeTests/src/com/android/emulator/smoketests/sms/SmsTest.java
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.android.emulator.sms.test;
+package com.android.emulator.smoketests.sms;
import android.content.Context;
import android.content.ContentResolver;
@@ -52,8 +52,10 @@ public class SmsTest {
public void testReceivedSms() throws java.lang.InterruptedException {
Cursor c = getSmsCursor();
c.moveToFirst();
+
String number = c.getString(c.getColumnIndexOrThrow("address"));
String body = c.getString(c.getColumnIndexOrThrow("body"));
+
c.close();
assertEquals(NUMBER, number);