Merge "Move suite-level dynamic config to testcases"

This commit is contained in:
Aaron Holden 2015-12-17 18:53:18 +00:00 committed by Android (Google) Code Review
commit 668cc135eb
2 changed files with 12 additions and 1 deletions

View File

@ -14,6 +14,7 @@
test_suite_name := cts_v2
test_suite_tradefed := cts-tradefed_v2
test_suite_dynamic_config := cts/tools/cts-tradefed/DynamicConfig.xml
test_suite_readme := cts/tools/cts-tradefed/README
include $(BUILD_SYSTEM)/tasks/tools/compatibility.mk

View File

@ -17,6 +17,7 @@
# Input variables:
# test_suite_name: the name of this test suite eg. cts
# test_suite_tradefed: the name of this test suite's tradefed wrapper
# test_suite_dynamic_config: the path to this test suite's dynamic configuration file
# test_suite_readme: the path to a README file for this test suite
# Output variables:
# compatibility_zip: the path to the output zip file.
@ -34,9 +35,18 @@ compatibility_zip := $(out_dir).zip
$(compatibility_zip): PRIVATE_NAME := android-$(test_suite_name)
$(compatibility_zip): PRIVATE_OUT_DIR := $(out_dir)
$(compatibility_zip): PRIVATE_TOOLS := $(test_tools)
$(compatibility_zip): $(test_artifacts) $(test_tools) | $(ADB) $(ACP)
$(compatibility_zip): PRIVATE_SUITE_NAME := $(test_suite_name)
$(compatibility_zip): PRIVATE_DYNAMIC_CONFIG := $(test_suite_dynamic_config)
$(compatibility_zip): $(test_artifacts) $(test_tools) $(test_suite_dynamic_config) | $(ADB) $(ACP)
# Make dir structure
$(hide) mkdir -p $(PRIVATE_OUT_DIR)/tools $(PRIVATE_OUT_DIR)/testcases
# Copy tools
$(hide) $(ACP) -fp $(PRIVATE_TOOLS) $(PRIVATE_OUT_DIR)/tools
$(if $(PRIVATE_DYNAMIC_CONFIG),$(hide) $(ACP) -fp $(PRIVATE_DYNAMIC_CONFIG) $(PRIVATE_OUT_DIR)/testcases/$(PRIVATE_SUITE_NAME).dynamic)
$(hide) cd $(dir $@) && zip -rq $(notdir $@) $(PRIVATE_NAME)
# Reset all input variables
test_suite_name :=
test_suite_tradefed :=
test_suite_dynamic_config :=
test_suite_readme :=