Bug 1208320 - Produce common tests archive via Python; r?glandium
This doesn't change I/O or copy behavior at all. But it does remove a
one-off make rule.
--- a/python/mozbuild/mozbuild/action/test_archive.py
+++ b/python/mozbuild/mozbuild/action/test_archive.py
@@ -15,16 +15,31 @@ import os
import sys
from mozpack.files import FileFinder
from mozpack.mozjar import JarWriter
import mozpack.path as mozpath
ARCHIVE_FILES = {
+ 'common': [
+ {
+ 'source': 'stage',
+ 'base': '',
+ 'pattern': '**',
+ 'ignore': [
+ 'cppunittest/**',
+ 'mochitest/**',
+ 'reftest/**',
+ 'talos/**',
+ 'web-platform/**',
+ 'xpcshell/**',
+ ],
+ },
+ ],
'mochitest': [
{
'source': 'topobjdir',
'base': '_tests/testing',
'pattern': 'mochitest/**',
},
{
'source': 'stage',
--- a/testing/testsuite-targets.mk
+++ b/testing/testsuite-targets.mk
@@ -393,16 +393,17 @@ stage-all: stage-steeplechase
endif
TEST_PKGS := \
cppunittest \
reftest \
$(NULL)
PYTHON_TEST_PKGS := \
+ common \
mochitest \
talos \
web-platform \
xpcshell \
$(NULL)
ALL_TEST_PKGS := $(TEST_PKGS) $(PYTHON_TEST_PKGS)
@@ -435,22 +436,16 @@ package-tests-mozharness: package-tests-
$(call py_action,test_archive, \
mozharness \
$(topsrcdir) \
$(abspath $(DEPTH)) \
$(abspath $(PKG_STAGE)) \
$(abspath $(DIST))/$(PKG_PATH)/mozharness.zip)
package-tests: package-tests-mozharness
-package-tests-common: stage-all package-tests-prepare-dest
- cd $(abspath $(PKG_STAGE)) && \
- zip -rq9D '$(abspath $(DIST))/$(PKG_PATH)$(TEST_PACKAGE)' \
- * -x \*/.mkdir.done \*.pyc $(foreach name,$(ALL_TEST_PKGS),$(name)\*)
-package-tests: package-tests-common
-
define package_archive
package-tests-$(1): stage-all package-tests-prepare-dest
rm -f '$$(DIST)/$$(PKG_PATH)$$(PKG_BASENAME).$(1).tests.zip' && \
cd $$(abspath $(PKG_STAGE)) && \
zip -rq9D '$$(abspath $$(DIST))/$$(PKG_PATH)$$(PKG_BASENAME).$(1).tests.zip' \
$(1) -x \*/.mkdir.done \*.pyc ;
.PHONY += package-tests-$(1)
package-tests: package-tests-$(1)