The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 1 | # Copyright (C) 2008 The Android Open Source Project |
| 2 | # |
| 3 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | # you may not use this file except in compliance with the License. |
| 5 | # You may obtain a copy of the License at |
| 6 | # |
| 7 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | |
| 15 | cts_dir := $(HOST_OUT)/cts |
| 16 | cts_tools_src_dir := cts/tools |
| 17 | |
| 18 | cts_name := android-cts |
| 19 | |
Xavier Ducrohet | e743c53 | 2010-07-28 11:07:31 -0700 | [diff] [blame] | 20 | DDMLIB_JAR := $(HOST_OUT_JAVA_LIBRARIES)/ddmlib-prebuilt.jar |
Brett Chabot | 67bae7f | 2009-06-26 14:41:30 -0700 | [diff] [blame] | 21 | junit_host_jar := $(HOST_OUT_JAVA_LIBRARIES)/junit.jar |
Phil Dubach | 3b7521b | 2009-08-19 16:26:40 -0700 | [diff] [blame] | 22 | HOSTTESTLIB_JAR := $(HOST_OUT_JAVA_LIBRARIES)/hosttestlib.jar |
Brett Chabot | 358b247 | 2011-01-30 15:07:21 -0800 | [diff] [blame] | 23 | TF_JAR := $(HOST_OUT_JAVA_LIBRARIES)/tradefed-prebuilt.jar |
| 24 | CTS_TF_JAR := $(HOST_OUT_JAVA_LIBRARIES)/cts-tradefed.jar |
| 25 | CTS_TF_EXEC_PATH := $(HOST_OUT_EXECUTABLES)/cts-tradefed |
Brett Chabot | e847a39 | 2011-02-18 15:13:50 -0800 | [diff] [blame] | 26 | CTS_TF_README_PATH := $(cts_tools_src_dir)/tradefed-host/README |
Brett Chabot | 67bae7f | 2009-06-26 14:41:30 -0700 | [diff] [blame] | 27 | |
Ying Wang | 02d75da | 2012-08-21 11:54:49 -0700 | [diff] [blame] | 28 | VMTESTSTF_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,vm-tests-tf,HOST) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 29 | VMTESTSTF_JAR := $(VMTESTSTF_INTERMEDIATES)/android.core.vm-tests-tf.jar |
| 30 | |
Brian Carlstrom | b6a08f0 | 2010-05-28 17:02:57 -0700 | [diff] [blame] | 31 | CTS_CORE_CASE_LIST := \ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 32 | android.core.tests.libcore.package.dalvik \ |
| 33 | android.core.tests.libcore.package.com \ |
| 34 | android.core.tests.libcore.package.sun \ |
| 35 | android.core.tests.libcore.package.tests \ |
| 36 | android.core.tests.libcore.package.org \ |
| 37 | android.core.tests.libcore.package.libcore \ |
Jorg Pleumann | 6178820 | 2009-05-07 01:33:14 -0700 | [diff] [blame] | 38 | android.core.tests.runner |
Urs Grob | b3c6b2d | 2009-04-17 11:27:08 -0700 | [diff] [blame] | 39 | |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 40 | # Depend on the full package paths rather than the phony targets to avoid |
| 41 | # rebuilding the packages every time. |
| 42 | CTS_CORE_CASES := $(foreach pkg,$(CTS_CORE_CASE_LIST),$(call intermediates-dir-for,APPS,$(pkg))/package.apk) |
| 43 | |
Brian Muramatsu | fa3d88f | 2010-07-22 14:46:53 -0700 | [diff] [blame] | 44 | -include cts/CtsTestCaseList.mk |
| 45 | CTS_CASE_LIST := $(CTS_CORE_CASE_LIST) $(CTS_TEST_CASE_LIST) |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 46 | |
Joe Onorato | 8004266 | 2010-06-15 17:29:19 -0400 | [diff] [blame] | 47 | DEFAULT_TEST_PLAN := $(cts_dir)/$(cts_name)/resource/plans |
Ying Wang | 51a1ae1 | 2013-07-10 11:33:27 -0700 | [diff] [blame^] | 48 | CTS_TEST_CASE_LIST_FILES := $(foreach c, $(CTS_TEST_CASE_LIST), $(call intermediates-dir-for,APPS,$(c))/package.apk) |
Brett Chabot | 67bae7f | 2009-06-26 14:41:30 -0700 | [diff] [blame] | 49 | $(cts_dir)/all_cts_files_stamp: PRIVATE_JUNIT_HOST_JAR := $(junit_host_jar) |
Ying Wang | 51a1ae1 | 2013-07-10 11:33:27 -0700 | [diff] [blame^] | 50 | $(cts_dir)/all_cts_files_stamp: $(CTS_CORE_CASES) $(CTS_TEST_CASES) $(CTS_TEST_CASE_LIST_FILES) $(junit_host_jar) $(HOSTTESTLIB_JAR) $(CTS_HOST_LIBRARY_JARS) $(TF_JAR) $(VMTESTSTF_JAR) $(CTS_TF_JAR) $(CTS_TF_EXEC_PATH) $(CTS_TF_README_PATH) $(ACP) |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 51 | # Make necessary directory for CTS |
Brian Muramatsu | 1cf9e0e | 2010-12-06 12:49:13 -0800 | [diff] [blame] | 52 | $(hide) rm -rf $(PRIVATE_CTS_DIR) |
| 53 | $(hide) mkdir -p $(TMP_DIR) |
| 54 | $(hide) mkdir -p $(PRIVATE_DIR)/docs |
| 55 | $(hide) mkdir -p $(PRIVATE_DIR)/tools |
| 56 | $(hide) mkdir -p $(PRIVATE_DIR)/repository/testcases |
| 57 | $(hide) mkdir -p $(PRIVATE_DIR)/repository/plans |
Brian Muramatsu | 45a971d | 2010-09-02 12:36:59 -0700 | [diff] [blame] | 58 | # Copy executable and JARs to CTS directory |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 59 | $(hide) $(ACP) -fp $(VMTESTSTF_JAR) $(PRIVATE_DIR)/repository/testcases |
Brian Muramatsu | 277be2f | 2011-11-03 11:34:06 -0700 | [diff] [blame] | 60 | $(hide) $(ACP) -fp $(DDMLIB_JAR) $(PRIVATE_JUNIT_HOST_JAR) $(HOSTTESTLIB_JAR) $(CTS_HOST_LIBRARY_JARS) $(TF_JAR) $(CTS_TF_JAR) $(CTS_TF_EXEC_PATH) $(CTS_TF_README_PATH) $(PRIVATE_DIR)/tools |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 61 | # Change mode of the executables |
Brian Muramatsu | 237fa07 | 2011-12-12 23:54:49 -0800 | [diff] [blame] | 62 | $(foreach apk,$(CTS_CASE_LIST),$(call copy-testcase-apk,$(apk))) |
| 63 | $(foreach testcase,$(CTS_TEST_CASES),$(call copy-testcase,$(testcase))) |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 64 | $(hide) touch $@ |
| 65 | |
Urs Grob | b3c6b2d | 2009-04-17 11:27:08 -0700 | [diff] [blame] | 66 | # Generate the test descriptions for the core-tests |
Phil Dubach | c539dbe | 2009-08-07 10:59:04 -0700 | [diff] [blame] | 67 | # Parameters: |
| 68 | # $1 : The output file where the description should be written (without the '.xml' extension) |
| 69 | # $2 : The AndroidManifest.xml corresponding to the test package |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 70 | # $3 : The jar file name on PRIVATE_CLASSPATH containing junit tests to search for |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 71 | # $4 : The package prefix of classes to include, possible empty |
| 72 | # $5 : The directory containing vogar expectations files |
| 73 | # $6 : The Android.mk corresponding to the test package (required for host-side tests only) |
Urs Grob | b3c6b2d | 2009-04-17 11:27:08 -0700 | [diff] [blame] | 74 | define generate-core-test-description |
| 75 | @echo "Generate core-test description ("$(notdir $(1))")" |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 76 | $(hide) java -Xmx256M \ |
Kenny Root | 65307c0 | 2013-02-27 16:55:56 -0800 | [diff] [blame] | 77 | -Xbootclasspath/a:$(PRIVATE_CLASSPATH) \ |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 78 | -classpath $(PRIVATE_CLASSPATH):$(HOST_OUT_JAVA_LIBRARIES)/descGen.jar:$(HOST_JDK_TOOLS_JAR) \ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 79 | $(PRIVATE_PARAMS) CollectAllTests $(1) $(2) $(3) "$(4)" $(5) $(6) |
Urs Grob | b3c6b2d | 2009-04-17 11:27:08 -0700 | [diff] [blame] | 80 | endef |
The Android Open Source Project | 6a5f7f0 | 2009-03-05 14:34:30 -0800 | [diff] [blame] | 81 | |
| 82 | CORE_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,core,,COMMON) |
Kenny Root | dfaf384 | 2013-04-29 13:25:29 -0700 | [diff] [blame] | 83 | CONSCRYPT_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,conscrypt,,COMMON) |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 84 | BOUNCYCASTLE_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,bouncycastle,,COMMON) |
| 85 | APACHEXML_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,apache-xml,,COMMON) |
jwilson | 190dde0 | 2013-03-30 09:00:01 -0400 | [diff] [blame] | 86 | OKHTTP_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,okhttp,,COMMON) |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 87 | SQLITEJDBC_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,sqlite-jdbc,,COMMON) |
Brian Carlstrom | d05d74b | 2010-05-28 18:47:17 -0700 | [diff] [blame] | 88 | JUNIT_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,core-junit,,COMMON) |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 89 | CORETESTS_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,core-tests,,COMMON) |
| 90 | |
Kenny Root | dfaf384 | 2013-04-29 13:25:29 -0700 | [diff] [blame] | 91 | GEN_CLASSPATH := $(CORE_INTERMEDIATES)/classes.jar:$(CONSCRYPT_INTERMEDIATES)/classes.jar:$(BOUNCYCASTLE_INTERMEDIATES)/classes.jar:$(APACHEXML_INTERMEDIATES)/classes.jar:$(OKHTTP_INTERMEDIATES)/classes.jar:$(JUNIT_INTERMEDIATES)/classes.jar:$(SQLITEJDBC_INTERMEDIATES)/javalib.jar:$(CORETESTS_INTERMEDIATES)/javalib.jar |
The Android Open Source Project | 6a5f7f0 | 2009-03-05 14:34:30 -0800 | [diff] [blame] | 92 | |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 93 | CTS_CORE_XMLS := \ |
| 94 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.dalvik.xml \ |
| 95 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.com.xml \ |
| 96 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.sun.xml \ |
| 97 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.tests.xml \ |
| 98 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.org.xml \ |
| 99 | $(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.libcore.xml |
| 100 | |
| 101 | $(CTS_CORE_XMLS): PRIVATE_CLASSPATH:=$(GEN_CLASSPATH) |
The Android Open Source Project | 6a5f7f0 | 2009-03-05 14:34:30 -0800 | [diff] [blame] | 102 | # Why does this depend on javalib.jar instead of classes.jar? Because |
| 103 | # even though the tool will operate on the classes.jar files, the |
| 104 | # build system requires that dependencies use javalib.jar. If |
| 105 | # javalib.jar is up-to-date, then classes.jar is as well. Depending |
| 106 | # on classes.jar will build the files incorrectly. |
jwilson | 190dde0 | 2013-03-30 09:00:01 -0400 | [diff] [blame] | 107 | $(CTS_CORE_XMLS): $(CTS_CORE_CASES) $(HOST_OUT_JAVA_LIBRARIES)/descGen.jar $(CORE_INTERMEDIATES)/javalib.jar $(BOUNCYCASTLE_INTERMEDIATES)/javalib.jar $(APACHEXML_INTERMEDIATES)/javalib.jar $(OKHTTP_INTERMEDIATES)/javalib.jar $(SQLITEJDBC_INTERMEDIATES)/javalib.jar $(JUNIT_INTERMEDIATES)/javalib.jar $(CORETESTS_INTERMEDIATES)/javalib.jar | $(ACP) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 108 | $(hide) mkdir -p $(CTS_TESTCASES_OUT) |
| 109 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.dalvik,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 110 | cts/tests/core/libcore/dalvik/AndroidManifest.xml,\ |
| 111 | $(CORETESTS_INTERMEDIATES)/javalib.jar,dalvik,\ |
| 112 | libcore/expectations) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 113 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.com,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 114 | cts/tests/core/libcore/com/AndroidManifest.xml,\ |
| 115 | $(CORETESTS_INTERMEDIATES)/javalib.jar,com,\ |
| 116 | libcore/expectations) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 117 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.sun,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 118 | cts/tests/core/libcore/sun/AndroidManifest.xml,\ |
| 119 | $(CORETESTS_INTERMEDIATES)/javalib.jar,sun,\ |
| 120 | libcore/expectations) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 121 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.tests,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 122 | cts/tests/core/libcore/tests/AndroidManifest.xml,\ |
| 123 | $(CORETESTS_INTERMEDIATES)/javalib.jar,tests,\ |
| 124 | libcore/expectations) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 125 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.org,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 126 | cts/tests/core/libcore/org/AndroidManifest.xml,\ |
| 127 | $(CORETESTS_INTERMEDIATES)/javalib.jar,org,\ |
| 128 | libcore/expectations) |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 129 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.tests.libcore.package.libcore,\ |
Brian Carlstrom | af85000 | 2011-05-27 00:04:57 -0700 | [diff] [blame] | 130 | cts/tests/core/libcore/libcore/AndroidManifest.xml,\ |
| 131 | $(CORETESTS_INTERMEDIATES)/javalib.jar,libcore,\ |
Brian Carlstrom | bb7c6d8 | 2011-04-01 15:45:58 -0700 | [diff] [blame] | 132 | libcore/expectations) |
The Android Open Source Project | 6a5f7f0 | 2009-03-05 14:34:30 -0800 | [diff] [blame] | 133 | |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 134 | # ----- Generate the test descriptions for the vm-tests-tf ----- |
| 135 | # |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 136 | CORE_VM_TEST_TF_DESC := $(CTS_TESTCASES_OUT)/android.core.vm-tests-tf.xml |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 137 | |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 138 | # core tests only needed to get hold of junit-framework-classes |
| 139 | CORE_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,core,,COMMON) |
| 140 | JUNIT_INTERMEDIATES :=$(call intermediates-dir-for,JAVA_LIBRARIES,core-junit,,COMMON) |
| 141 | |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 142 | GEN_CLASSPATH := $(CORE_INTERMEDIATES)/classes.jar:$(JUNIT_INTERMEDIATES)/classes.jar:$(VMTESTSTF_JAR):$(DDMLIB_JAR):$(TF_JAR) |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 143 | |
| 144 | $(CORE_VM_TEST_TF_DESC): PRIVATE_CLASSPATH:=$(GEN_CLASSPATH) |
| 145 | # Please see big comment above on why this line depends on javalib.jar instead of classes.jar |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 146 | $(CORE_VM_TEST_TF_DESC): $(HOST_OUT_JAVA_LIBRARIES)/descGen.jar $(CORE_INTERMEDIATES)/javalib.jar $(JUNIT_INTERMEDIATES)/javalib.jar $(VMTESTSTF_JAR) $(DDMLIB_JAR) | $(ACP) |
| 147 | $(hide) mkdir -p $(CTS_TESTCASES_OUT) |
| 148 | $(call generate-core-test-description,$(CTS_TESTCASES_OUT)/android.core.vm-tests-tf,\ |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 149 | cts/tests/vm-tests-tf/AndroidManifest.xml,\ |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 150 | $(VMTESTSTF_JAR),"",\ |
Tsu Chiang Chuang | 9d047ac | 2011-04-27 17:01:32 -0700 | [diff] [blame] | 151 | libcore/expectations,\ |
| 152 | cts/tools/vm-tests-tf/Android.mk) |
Brian Muramatsu | 237fa07 | 2011-12-12 23:54:49 -0800 | [diff] [blame] | 153 | |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 154 | # Generate the default test plan for User. |
Phil Dubach | 5e3ab04 | 2009-08-14 13:48:34 -0700 | [diff] [blame] | 155 | # Usage: buildCts.py <testRoot> <ctsOutputDir> <tempDir> <androidRootDir> <docletPath> |
Brian Muramatsu | 237fa07 | 2011-12-12 23:54:49 -0800 | [diff] [blame] | 156 | |
Brian Muramatsu | c0a6924 | 2012-01-05 18:24:43 -0800 | [diff] [blame] | 157 | $(DEFAULT_TEST_PLAN): $(cts_dir)/all_cts_files_stamp $(cts_tools_src_dir)/utils/buildCts.py $(HOST_OUT_JAVA_LIBRARIES)/descGen.jar $(CTS_CORE_XMLS) $(CTS_TEST_XMLS) $(CORE_VM_TEST_TF_DESC) | $(ACP) |
| 158 | $(hide) $(ACP) -fp $(CTS_CORE_XMLS) $(CTS_TEST_XMLS) $(CORE_VM_TEST_TF_DESC) $(PRIVATE_DIR)/repository/testcases |
Phil Dubach | 5e3ab04 | 2009-08-14 13:48:34 -0700 | [diff] [blame] | 159 | $(hide) $(cts_tools_src_dir)/utils/buildCts.py cts/tests/tests/ $(PRIVATE_DIR) $(TMP_DIR) \ |
| 160 | $(TOP) $(HOST_OUT_JAVA_LIBRARIES)/descGen.jar |
Ying Wang | 51a1ae1 | 2013-07-10 11:33:27 -0700 | [diff] [blame^] | 161 | $(hide) mkdir -p $(dir $@) && touch $@ |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 162 | |
| 163 | # Package CTS and clean up. |
| 164 | # |
| 165 | # TODO: |
| 166 | # Pack cts.bat into the same zip file as well. See http://buganizer/issue?id=1656821 for more details |
| 167 | INTERNAL_CTS_TARGET := $(cts_dir)/$(cts_name).zip |
| 168 | $(INTERNAL_CTS_TARGET): PRIVATE_NAME := $(cts_name) |
| 169 | $(INTERNAL_CTS_TARGET): PRIVATE_CTS_DIR := $(cts_dir) |
| 170 | $(INTERNAL_CTS_TARGET): PRIVATE_DIR := $(cts_dir)/$(cts_name) |
| 171 | $(INTERNAL_CTS_TARGET): TMP_DIR := $(cts_dir)/temp |
Brian Muramatsu | 5fc0057 | 2011-12-16 13:07:15 -0800 | [diff] [blame] | 172 | $(INTERNAL_CTS_TARGET): $(cts_dir)/all_cts_files_stamp $(DEFAULT_TEST_PLAN) |
Brian Muramatsu | 1cf9e0e | 2010-12-06 12:49:13 -0800 | [diff] [blame] | 173 | $(hide) echo "Package CTS: $@" |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 174 | $(hide) cd $(dir $@) && zip -rq $(notdir $@) $(PRIVATE_NAME) |
| 175 | |
| 176 | .PHONY: cts |
| 177 | cts: $(INTERNAL_CTS_TARGET) adb |
| 178 | $(call dist-for-goals,cts,$(INTERNAL_CTS_TARGET)) |
| 179 | |
| 180 | define copy-testcase-apk |
| 181 | |
Brian Muramatsu | 9353a3b | 2011-09-07 18:12:22 -0700 | [diff] [blame] | 182 | $(hide) $(ACP) -fp $(call intermediates-dir-for,APPS,$(1))/package.apk \ |
The Android Open Source Project | 88b6079 | 2009-03-03 19:28:42 -0800 | [diff] [blame] | 183 | $(PRIVATE_DIR)/repository/testcases/$(1).apk |
| 184 | |
| 185 | endef |
Brian Muramatsu | 237fa07 | 2011-12-12 23:54:49 -0800 | [diff] [blame] | 186 | |
| 187 | define copy-testcase |
| 188 | |
| 189 | $(hide) $(ACP) -fp $(1) $(PRIVATE_DIR)/repository/testcases/$(notdir $1) |
| 190 | |
| 191 | endef |