Convert hostsidetests/appsecurity/Android.mk to Android.bp
Test: atest CtsAppSecurityHostTestCases:android.appsecurity.cts.CorruptApkTests
Test: atest a few others (since the first few seems to crash the system)
Bug: 122332514
Bug: 153112812
Change-Id: Iab84f36509cc34032178eec38d1fcc0e317939cd
Merged-In: Iab84f36509cc34032178eec38d1fcc0e317939cd
diff --git a/hostsidetests/appsecurity/Android.bp b/hostsidetests/appsecurity/Android.bp
index 31ed981..7700a82 100644
--- a/hostsidetests/appsecurity/Android.bp
+++ b/hostsidetests/appsecurity/Android.bp
@@ -1,3 +1,49 @@
+// Copyright (C) 2009 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.
+
+java_test_host {
+ name: "CtsAppSecurityHostTestCases",
+ defaults: ["cts_defaults"],
+
+ // Only compile source java files in this apk.
+ srcs: ["src/**/*.java"],
+
+ libs: [
+ "cts-tradefed",
+ "tradefed",
+ "compatibility-host-util",
+ ],
+
+ java_resource_dirs: ["res"],
+
+ // tag this module as a cts test artifact
+ test_suites: [
+ "cts",
+ "vts10",
+ "general-tests",
+ "mts",
+ "sts",
+ ],
+
+ required: [
+ "CtsCorruptApkTests_b71360999",
+ "CtsCorruptApkTests_b71361168",
+ "CtsCorruptApkTests_b79488511",
+ ],
+
+}
+
filegroup {
name: "CtsHostsideTestsAppSecurityUtil",
srcs: ["src/android/appsecurity/cts/Utils.java"],
diff --git a/hostsidetests/appsecurity/Android.mk b/hostsidetests/appsecurity/Android.mk
index 7308e07..4b1e9ac 100644
--- a/hostsidetests/appsecurity/Android.mk
+++ b/hostsidetests/appsecurity/Android.mk
@@ -14,28 +14,5 @@
LOCAL_PATH := $(call my-dir)
-include $(CLEAR_VARS)
-
-# Only compile source java files in this apk.
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_MODULE := CtsAppSecurityHostTestCases
-
-LOCAL_JAVA_LIBRARIES := cts-tradefed tradefed compatibility-host-util
-
-LOCAL_JAVA_RESOURCE_DIRS := res
-
-LOCAL_CTS_TEST_PACKAGE := android.appsecurity
-
-# tag this module as a cts test artifact
-LOCAL_COMPATIBILITY_SUITE := cts vts10 general-tests mts sts
-
-LOCAL_REQUIRED_MODULES := \
- CtsCorruptApkTests_b71360999 \
- CtsCorruptApkTests_b71361168 \
- CtsCorruptApkTests_b79488511
-
-include $(BUILD_CTS_HOST_JAVA_LIBRARY)
-
# Build the test APKs using their own makefiles
include $(call all-makefiles-under,$(LOCAL_PATH))