Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d2348198 authored by Simran Basi's avatar Simran Basi Committed by Ryan Longair
Browse files

Output *TS testcases to their own subdir in the common testcase folders.

Instead of dumping all *TS testcases into the common testcase
directory directly, place them all in their own subdirectory.

Bug: 35153177
Test: `make cts -j` and checked the contents of both:
out/host/linux-x86/testcases/ &
out/host/linux-x86/cts/android-cts/testcases/

Change-Id: I22a768dba58d40be1e61885534fb813e7ff08c99
(cherry picked from commit 3fb354cc)
Merged-In: I22a768dba58d40be1e61885534fb813e7ff08c99
parent 27c29368
Loading
Loading
Loading
Loading
+7 −4
Original line number Diff line number Diff line
@@ -375,10 +375,13 @@ ifneq ($(words $(LOCAL_COMPATIBILITY_SUITE)),1)
$(error $(LOCAL_PATH):$(LOCAL_MODULE) LOCAL_COMPATIBILITY_SUITE can be only one name)
endif

# Copy this module into its own subdirectory in the common testcases output directory.
my_testcases_subdir := $($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE)

# The module itself.
my_compat_dist := \
  $(LOCAL_BUILT_MODULE):$(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(my_installed_module_stem) \
  $(LOCAL_BUILT_MODULE):$($(my_prefix)OUT_TESTCASES)/$(my_installed_module_stem)
  $(LOCAL_BUILT_MODULE):$(my_testcases_subdir)/$(my_installed_module_stem)

# Make sure we only add the files once for multilib modules.
ifndef $(my_prefix)$(LOCAL_MODULE_CLASS)_$(LOCAL_MODULE)_compat_files
@@ -390,20 +393,20 @@ my_compat_dist += $(foreach f, $(LOCAL_COMPATIBILITY_SUPPORT_FILES),\
  $(eval s := $(word 1,$(p)))\
  $(eval n := $(or $(word 2,$(p)),$(notdir $(word 1, $(p))))) \
  $(eval d := $(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(n)) \
  $(s):$(d) $(s):$($(my_prefix)OUT_TESTCASES)/$(n))
  $(s):$(d) $(s):$(my_testcases_subdir)/$(n))

ifneq (,$(wildcard $(LOCAL_PATH)/AndroidTest.xml))
my_compat_dist += \
  $(LOCAL_PATH)/AndroidTest.xml:$(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(LOCAL_MODULE).config
my_compat_dist += \
  $(LOCAL_PATH)/AndroidTest.xml:$($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE).config
  $(LOCAL_PATH)/AndroidTest.xml:$(my_testcases_subdir)/$(LOCAL_MODULE).config
endif

ifneq (,$(wildcard $(LOCAL_PATH)/DynamicConfig.xml))
my_compat_dist += \
  $(LOCAL_PATH)/DynamicConfig.xml:$(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(LOCAL_MODULE).dynamic
my_compat_dist += \
  $(LOCAL_PATH)/DynamicConfig.xml:$($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE).dynamic
  $(LOCAL_PATH)/DynamicConfig.xml:$(my_testcases_subdir)/$(LOCAL_MODULE).dynamic
endif
endif # $(my_prefix)$(LOCAL_MODULE_CLASS)_$(LOCAL_MODULE)_compat_files

+2 −2
Original line number Diff line number Diff line
@@ -639,8 +639,8 @@ ifdef LOCAL_COMPATIBILITY_SUITE
cts_testcase_file := $(foreach s,$(my_split_suffixes),$(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(LOCAL_MODULE)_$(s).apk)
$(cts_testcase_file) : $(COMPATIBILITY_TESTCASES_OUT_$(LOCAL_COMPATIBILITY_SUITE))/$(LOCAL_MODULE)_%.apk : $(built_module_path)/package_%.apk | $(ACP)
	$(copy-file-to-new-target)
common_testcase_file := $(foreach s,$(my_split_suffixes),$($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE)_$(s).apk)
$(common_testcase_file) : $($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE)_%.apk : $(built_module_path)/package_%.apk
common_testcase_file := $(foreach s,$(my_split_suffixes),$($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE)/$(LOCAL_MODULE)_$(s).apk)
$(common_testcase_file) : $($(my_prefix)OUT_TESTCASES)/$(LOCAL_MODULE)/$(LOCAL_MODULE)_%.apk : $(built_module_path)/package_%.apk
	$(copy-file-to-new-target)

COMPATIBILITY.$(LOCAL_COMPATIBILITY_SUITE).FILES := \