Merge "Migrate CtsWidgetTestCases to Android bp"
diff --git a/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/LockTaskHostDrivenTest.java b/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/LockTaskHostDrivenTest.java
index b2ae2cc..72bebcf 100644
--- a/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/LockTaskHostDrivenTest.java
+++ b/hostsidetests/devicepolicy/app/DeviceOwner/src/com/android/cts/deviceowner/LockTaskHostDrivenTest.java
@@ -32,6 +32,7 @@
 
 import org.junit.After;
 import org.junit.Before;
+import org.junit.After;
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
diff --git a/tests/autofillservice/AndroidTest.xml b/tests/autofillservice/AndroidTest.xml
index e7413b1..53ab5ff 100644
--- a/tests/autofillservice/AndroidTest.xml
+++ b/tests/autofillservice/AndroidTest.xml
@@ -36,4 +36,10 @@
     <option name="shell-timeout" value="12000000"/>
   </test>
 
+  <!-- Collect the files generated on error -->
+  <metrics_collector class="com.android.tradefed.device.metric.FilePullerLogCollector">
+    <option name="directory-keys" value="/sdcard/CtsAutoFillServiceTestCases" />
+    <option name="collect-on-run-ended-only" value="true" />
+    <option name="clean-up" value="false" />
+  </metrics_collector>
 </configuration>
diff --git a/tests/autofillservice/src/android/autofillservice/cts/LoginActivityTest.java b/tests/autofillservice/src/android/autofillservice/cts/LoginActivityTest.java
index e39cdf9..371a4a1 100644
--- a/tests/autofillservice/src/android/autofillservice/cts/LoginActivityTest.java
+++ b/tests/autofillservice/src/android/autofillservice/cts/LoginActivityTest.java
@@ -416,9 +416,10 @@
 
     @Test
     public void testDatasetPickerPosition() throws Exception {
-        // TODO: currently disabled because the screenshot contains elements external to the
-        // activity that can change (for exmaple, clock), which causes flakiness to the test.
+        // TODO(b/75281985): currently disabled because the screenshot contains elements external to
+        // the activity that can change (for exmaple, clock), which causes flakiness to the test.
         final boolean compareBitmaps = false;
+
         final boolean pickerAndViewBoundsMatches = !isAutofillWindowFullScreen(mContext);
 
         // Set service.
diff --git a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureActivity.java b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureActivity.java
index f8f8092..072c770 100644
--- a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureActivity.java
+++ b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureActivity.java
@@ -15,7 +15,7 @@
  */
 package android.contentcaptureservice.cts;
 
-import static android.contentcaptureservice.cts.common.ShellHelper.runShellCommand;
+import static com.android.compatibility.common.util.ShellUtils.runShellCommand;
 
 import android.app.Activity;
 import android.contentcaptureservice.cts.CtsContentCaptureService.Session;
diff --git a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureIntegrationTest.java b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureIntegrationTest.java
index e827a62..afcc95e 100644
--- a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureIntegrationTest.java
+++ b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/AbstractContentCaptureIntegrationTest.java
@@ -20,9 +20,10 @@
 import static android.contentcaptureservice.cts.Helper.resetService;
 import static android.contentcaptureservice.cts.Helper.sContext;
 import static android.contentcaptureservice.cts.Helper.setService;
-import static android.contentcaptureservice.cts.common.ShellHelper.runShellCommand;
 import static android.provider.Settings.Secure.CONTENT_CAPTURE_ENABLED;
 
+import static com.android.compatibility.common.util.ShellUtils.runShellCommand;
+
 import android.app.Application;
 import android.content.Intent;
 import android.contentcaptureservice.cts.CtsContentCaptureService.ServiceWatcher;
diff --git a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/ContentCaptureLoggingTestRule.java b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/ContentCaptureLoggingTestRule.java
index c7b831a..f829c60 100644
--- a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/ContentCaptureLoggingTestRule.java
+++ b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/ContentCaptureLoggingTestRule.java
@@ -18,7 +18,8 @@
 
 import static android.contentcaptureservice.cts.Helper.MY_PACKAGE;
 import static android.contentcaptureservice.cts.Helper.TAG;
-import static android.contentcaptureservice.cts.common.ShellHelper.runShellCommand;
+
+import static com.android.compatibility.common.util.ShellUtils.runShellCommand;
 
 import android.util.Log;
 
diff --git a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/Helper.java b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/Helper.java
index fbbd454..3b78e21 100644
--- a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/Helper.java
+++ b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/Helper.java
@@ -15,7 +15,7 @@
  */
 package android.contentcaptureservice.cts;
 
-import static android.contentcaptureservice.cts.common.ShellHelper.runShellCommand;
+import static com.android.compatibility.common.util.ShellUtils.runShellCommand;
 
 import android.content.ComponentName;
 import android.content.Context;
diff --git a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/common/ShellHelper.java b/tests/contentcaptureservice/src/android/contentcaptureservice/cts/common/ShellHelper.java
deleted file mode 100644
index a9b1481..0000000
--- a/tests/contentcaptureservice/src/android/contentcaptureservice/cts/common/ShellHelper.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (C) 2018 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.
- */
-
-package android.contentcaptureservice.cts.common;
-
-import android.support.test.InstrumentationRegistry;
-import android.text.TextUtils;
-import android.util.Log;
-
-import androidx.annotation.NonNull;
-
-import com.android.compatibility.common.util.SystemUtil;
-
-/**
- * Provides Shell-based utilities such as running a command.
- */
-public final class ShellHelper {
-
-    private static final String TAG = "ShellHelper";
-
-    /**
-     * Runs a Shell command, returning a trimmed response.
-     */
-    @NonNull
-    public static String runShellCommand(@NonNull String template, Object... args) {
-        final String command = String.format(template, args);
-        Log.d(TAG, "runShellCommand(): " + command);
-        try {
-            final String result = SystemUtil
-                    .runShellCommand(InstrumentationRegistry.getInstrumentation(), command);
-            return TextUtils.isEmpty(result) ? "" : result.trim();
-        } catch (Exception e) {
-            throw new RuntimeException("Command '" + command + "' failed: ", e);
-        }
-    }
-
-    private ShellHelper() {
-        throw new UnsupportedOperationException("contain static methods only");
-    }
-}
diff --git a/tests/tests/alarmclock/src/android/alarmclock/cts/DismissTimerTest.java b/tests/tests/alarmclock/src/android/alarmclock/cts/DismissTimerTest.java
index 31cb55a..a4c0d0a 100644
--- a/tests/tests/alarmclock/src/android/alarmclock/cts/DismissTimerTest.java
+++ b/tests/tests/alarmclock/src/android/alarmclock/cts/DismissTimerTest.java
@@ -3,7 +3,6 @@
 import android.alarmclock.common.Utils;
 import android.content.Context;
 import android.media.AudioManager;
-import android.support.test.filters.Suppress;
 
 public class DismissTimerTest extends AlarmClockTestBase {
 
@@ -28,7 +27,6 @@
         audioManager.setStreamVolume(AudioManager.STREAM_ALARM, mSavedVolume, 0);
     }
 
-    @Suppress // b/122662463 - Flaky on AOSP
     public void testAll() throws Exception {
         assertEquals(Utils.COMPLETION_RESULT, runTest(Utils.TestcaseType.SET_TIMER_FOR_DISMISSAL));
         try {
diff --git a/tests/tests/alarmclock/src/android/alarmclock/cts/SetAlarmTest.java b/tests/tests/alarmclock/src/android/alarmclock/cts/SetAlarmTest.java
index ec1e349..a95a1dd 100644
--- a/tests/tests/alarmclock/src/android/alarmclock/cts/SetAlarmTest.java
+++ b/tests/tests/alarmclock/src/android/alarmclock/cts/SetAlarmTest.java
@@ -18,14 +18,12 @@
 
 import android.alarmclock.common.Utils;
 import android.alarmclock.common.Utils.TestcaseType;
-import android.support.test.filters.Suppress;
 
 public class SetAlarmTest extends AlarmClockTestBase {
     public SetAlarmTest() {
         super();
     }
 
-    @Suppress // b/122662463 - Flaky on AOSP
     public void testAll() throws Exception {
         assertEquals(Utils.COMPLETION_RESULT, runTest(TestcaseType.SET_ALARM));
     }
diff --git a/tests/tests/appwidget/AndroidTest.xml b/tests/tests/appwidget/AndroidTest.xml
index 4b19277..8b193fb 100644
--- a/tests/tests/appwidget/AndroidTest.xml
+++ b/tests/tests/appwidget/AndroidTest.xml
@@ -16,6 +16,7 @@
     <option name="test-suite-tag" value="cts" />
     <option name="config-descriptor:metadata" key="component" value="framework" />
     <option name="config-descriptor:metadata" key="parameter" value="instant_app" />
+    <option name="config-descriptor:metadata" key="parameter" value="multi_abi" />
     <target_preparer class="com.android.tradefed.targetprep.suite.SuiteApkInstaller">
         <option name="cleanup-apks" value="true" />
         <option name="test-file-name" value="CtsAppWidgetLauncher1.apk" />
diff --git a/tests/tests/notificationlegacy/notificationlegacy29/src/android/app/notification/legacy29/cts/NotificationAssistantServiceTest.java b/tests/tests/notificationlegacy/notificationlegacy29/src/android/app/notification/legacy29/cts/NotificationAssistantServiceTest.java
index 71cf3f2..ff20d4d 100644
--- a/tests/tests/notificationlegacy/notificationlegacy29/src/android/app/notification/legacy29/cts/NotificationAssistantServiceTest.java
+++ b/tests/tests/notificationlegacy/notificationlegacy29/src/android/app/notification/legacy29/cts/NotificationAssistantServiceTest.java
@@ -36,6 +36,7 @@
 import android.os.ParcelFileDescriptor;
 import android.provider.Telephony;
 import android.service.notification.Adjustment;
+import android.service.notification.NotificationAssistantService;
 import android.service.notification.NotificationListenerService;
 import android.service.notification.StatusBarNotification;
 import android.support.test.InstrumentationRegistry;
@@ -250,6 +251,52 @@
         assertTrue(replyFound);
     }
 
+    @Test
+    public void testOnActionInvoked_methodExists() throws Exception {
+        setUpListeners();
+        final Intent intent = new Intent(Intent.ACTION_MAIN, Telephony.Threads.CONTENT_URI);
+
+        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_SINGLE_TOP
+                | Intent.FLAG_ACTIVITY_CLEAR_TOP);
+        intent.setAction(Intent.ACTION_MAIN);
+
+        final PendingIntent pendingIntent = PendingIntent.getActivity(mContext, 0, intent, 0);
+        Notification.Action action = new Notification.Action.Builder(null, "",
+                pendingIntent).build();
+        // This method has to exist and the call cannot fail
+        mNotificationAssistantService.onActionInvoked("", action,
+                NotificationAssistantService.SOURCE_FROM_APP);
+    }
+
+    @Test
+    public void testOnNotificationDirectReplied_methodExists() throws Exception {
+        setUpListeners();
+        // This method has to exist and the call cannot fail
+        mNotificationAssistantService.onNotificationDirectReplied("");
+    }
+
+    @Test
+    public void testOnNotificationExpansionChanged_methodExists() throws Exception {
+        setUpListeners();
+        // This method has to exist and the call cannot fail
+        mNotificationAssistantService.onNotificationExpansionChanged("", true, true);
+    }
+
+    @Test
+    public void testOnNotificationsSeen_methodExists() throws Exception {
+        setUpListeners();
+        // This method has to exist and the call cannot fail
+        mNotificationAssistantService.onNotificationsSeen(new ArrayList<String>());
+    }
+
+    @Test
+    public void testOnSuggestedReplySent_methodExists() throws Exception {
+        setUpListeners();
+        // This method has to exist and the call cannot fail
+        mNotificationAssistantService.onSuggestedReplySent("", "",
+                NotificationAssistantService.SOURCE_FROM_APP);
+    }
+
     private StatusBarNotification getFirstNotificationFromPackage(String PKG)
             throws InterruptedException {
         StatusBarNotification sbn = mNotificationListenerService.mPosted.poll(SLEEP_TIME,
diff --git a/tests/tests/permission2/res/raw/android_manifest.xml b/tests/tests/permission2/res/raw/android_manifest.xml
index 836214c..c2aa5fe 100644
--- a/tests/tests/permission2/res/raw/android_manifest.xml
+++ b/tests/tests/permission2/res/raw/android_manifest.xml
@@ -2286,7 +2286,7 @@
     <!-- Allows an application to start activities from background
          @hide -->
     <permission android:name="android.permission.START_ACTIVITIES_FROM_BACKGROUND"
-        android:protectionLevel="signature|privileged|vendorPrivileged|oem" />
+        android:protectionLevel="signature|privileged|vendorPrivileged|oem|verifier" />
 
     <!-- @SystemApi Must be required by activities that handle the intent action
          {@link Intent#ACTION_SEND_SHOW_SUSPENDED_APP_DETAILS}. This is for use by apps that
diff --git a/tests/tests/provider/src/android/provider/cts/MediaStoreTest.java b/tests/tests/provider/src/android/provider/cts/MediaStoreTest.java
index 4f0850a..792a00b 100644
--- a/tests/tests/provider/src/android/provider/cts/MediaStoreTest.java
+++ b/tests/tests/provider/src/android/provider/cts/MediaStoreTest.java
@@ -197,34 +197,6 @@
         }
     }
 
-    @Test
-    public void testHash() throws Exception {
-        final ContentResolver resolver = getContext().getContentResolver();
-
-        final Uri uri = ProviderTestUtils.stageMedia(R.raw.volantis, mExternalImages);
-        SystemClock.sleep(500);
-
-        final String expected = Arrays
-                .toString(HexEncoding.decode("dd41258ce8d306163f3b727603cb064be81973db"));
-
-        // We can force hash to be generated by requesting canonicalization
-        resolver.canonicalize(uri);
-        try (Cursor c = resolver.query(uri, new String[] { MediaColumns.HASH }, null, null)) {
-            assertTrue(c.moveToFirst());
-            assertEquals(expected, Arrays.toString(c.getBlob(0)));
-        }
-
-        // Make sure that editing image results in a different hash
-        try (OutputStream out = resolver.openOutputStream(uri, "wa")) {
-            out.write(42);
-        }
-        SystemClock.sleep(500);
-        try (Cursor c = resolver.query(uri, new String[] { MediaColumns.HASH }, null, null)) {
-            assertTrue(c.moveToFirst());
-            assertNotEquals(expected, Arrays.toString(c.getBlob(0)));
-        }
-    }
-
     private long getExternalPackageSize() throws Exception {
         final StorageManager storage = getContext().getSystemService(StorageManager.class);
         final StorageStatsManager stats = getContext().getSystemService(StorageStatsManager.class);
diff --git a/tests/tests/provider/src/android/provider/cts/MediaStoreTrashTest.java b/tests/tests/provider/src/android/provider/cts/MediaStoreTrashTest.java
deleted file mode 100644
index 97cd1ff..0000000
--- a/tests/tests/provider/src/android/provider/cts/MediaStoreTrashTest.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Copyright (C) 2018 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.
- */
-
-package android.provider.cts;
-
-import static android.provider.cts.MediaStoreTest.TAG;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import android.content.ContentResolver;
-import android.content.ContentUris;
-import android.content.Context;
-import android.database.Cursor;
-import android.net.Uri;
-import android.os.SystemClock;
-import android.provider.MediaStore;
-import android.provider.MediaStore.MediaColumns;
-import android.support.test.InstrumentationRegistry;
-import android.text.format.DateUtils;
-import android.util.Log;
-
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.junit.runners.Parameterized;
-import org.junit.runners.Parameterized.Parameter;
-import org.junit.runners.Parameterized.Parameters;
-
-@RunWith(Parameterized.class)
-public class MediaStoreTrashTest {
-    private Context mContext;
-    private ContentResolver mResolver;
-
-    private Uri mExternalImages;
-
-    @Parameter(0)
-    public String mVolumeName;
-
-    @Parameters
-    public static Iterable<? extends Object> data() {
-        return ProviderTestUtils.getSharedVolumeNames();
-    }
-
-    @Before
-    public void setUp() throws Exception {
-        mContext = InstrumentationRegistry.getTargetContext();
-        mResolver = mContext.getContentResolver();
-
-        Log.d(TAG, "Using volume " + mVolumeName);
-        mExternalImages = MediaStore.Images.Media.getContentUri(mVolumeName);
-    }
-
-    @Test
-    public void testTrashUntrash() throws Exception {
-        final Uri insertUri = mExternalImages;
-        final Uri uri = ProviderTestUtils.stageMedia(R.raw.volantis, insertUri);
-        final long id = ContentUris.parseId(uri);
-
-        // Default is not trashed, and no expiration date
-        try (Cursor c = mResolver.query(uri,
-                new String[] { MediaColumns.IS_TRASHED, MediaColumns.DATE_EXPIRES }, null, null)) {
-            assertTrue(c.moveToFirst());
-            assertEquals(0, c.getInt(0));
-            assertTrue(c.isNull(1));
-        }
-        assertTrue(containsId(insertUri, id));
-        assertTrue(containsId(MediaStore.setIncludeTrashed(insertUri), id));
-
-        // Trash should expire roughly 2 days from now
-        MediaStore.trash(mContext, uri);
-        try (Cursor c = mResolver.query(uri,
-                new String[] { MediaColumns.IS_TRASHED, MediaColumns.DATE_EXPIRES }, null, null)) {
-            assertTrue(c.moveToFirst());
-            assertEquals(1, c.getInt(0));
-            assertMostlyEquals((System.currentTimeMillis() + (2 * DateUtils.DAY_IN_MILLIS)) / 1000,
-                    c.getLong(1), 30);
-        }
-        assertFalse(containsId(insertUri, id));
-        assertTrue(containsId(MediaStore.setIncludeTrashed(insertUri), id));
-
-        // Untrash should bring us back
-        MediaStore.untrash(mContext, uri);
-        try (Cursor c = mResolver.query(uri,
-                new String[] { MediaColumns.IS_TRASHED, MediaColumns.DATE_EXPIRES }, null, null)) {
-            assertTrue(c.moveToFirst());
-            assertEquals(0, c.getInt(0));
-            assertTrue(c.isNull(1));
-        }
-        assertTrue(containsId(insertUri, id));
-        assertTrue(containsId(MediaStore.setIncludeTrashed(insertUri), id));
-    }
-
-    @Test
-    public void testTrashExecutes() throws Exception {
-        final Uri insertUri = mExternalImages;
-        final Uri uri = ProviderTestUtils.stageMedia(R.raw.volantis, insertUri);
-
-        MediaStore.trash(mContext, uri, 1);
-
-        // Force idle maintenance to run
-        ProviderTestUtils.executeShellCommand(
-                "cmd jobscheduler run -f com.android.providers.media -200",
-                InstrumentationRegistry.getInstrumentation().getUiAutomation());
-
-        // Wait around for item to be deleted
-        final long timeout = SystemClock.elapsedRealtime() + DateUtils.MINUTE_IN_MILLIS;
-        while (SystemClock.elapsedRealtime() < timeout) {
-            try (Cursor c = mResolver.query(uri, null, null, null)) {
-                Log.v(TAG, "Count " + c.getCount());
-                if (c.getCount() == 0) {
-                    return;
-                }
-            }
-            SystemClock.sleep(500);
-        }
-
-        fail("Timed out waiting for job to delete trashed item");
-    }
-
-    private boolean containsId(Uri uri, long id) {
-        try (Cursor c = mResolver.query(uri,
-                new String[] { MediaColumns._ID }, null, null)) {
-            while (c.moveToNext()) {
-                if (c.getLong(0) == id) return true;
-            }
-        }
-        return false;
-    }
-
-    private static void assertMostlyEquals(long expected, long actual, long delta) {
-        if (Math.abs(expected - actual) > delta) {
-            fail("Expected roughly " + expected + " but was " + actual);
-        }
-    }
-}
diff --git a/tests/tests/view/jni/Android.bp b/tests/tests/view/jni/Android.bp
new file mode 100644
index 0000000..61932fc
--- /dev/null
+++ b/tests/tests/view/jni/Android.bp
@@ -0,0 +1,40 @@
+// Copyright (C) 2016 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.
+
+cc_test_library {
+
+    name: "libctsview_jni",
+
+    cflags: ["-Werror"],
+
+    gtest: false,
+
+    srcs: [
+        "CtsViewJniOnLoad.cpp",
+        "android_view_cts_ASurfaceControlTest.cpp",
+        "android_view_cts_ChoreographerNativeTest.cpp",
+    ],
+
+    shared_libs: [
+        "libandroid",
+        "libnativehelper_compat_libc++",
+        "liblog",
+        "libsync",
+    ],
+
+    stl: "c++_static",
+
+    sdk_version: "current",
+
+}
diff --git a/tests/tests/view/jni/Android.mk b/tests/tests/view/jni/Android.mk
deleted file mode 100644
index 85c073b..0000000
--- a/tests/tests/view/jni/Android.mk
+++ /dev/null
@@ -1,38 +0,0 @@
-# Copyright (C) 2016 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 := libctsview_jni
-
-LOCAL_CFLAGS += -Werror
-
-LOCAL_MODULE_TAGS := tests
-
-LOCAL_SRC_FILES := \
-		CtsViewJniOnLoad.cpp \
-		android_view_cts_ASurfaceControlTest.cpp \
-		android_view_cts_ChoreographerNativeTest.cpp
-
-LOCAL_C_INCLUDES := $(JNI_H_INCLUDE)
-
-LOCAL_SHARED_LIBRARIES := libandroid libnativehelper_compat_libc++ liblog libsync
-
-LOCAL_NDK_STL_VARIANT := c++_static
-
-LOCAL_SDK_VERSION := current
-
-include $(BUILD_SHARED_LIBRARY)