Bug 1393607 Do not package tests if they are not enabled
MozReview-Commit-ID: 1wQV41Nf8V5
--- a/build/moz-automation.mk
+++ b/build/moz-automation.mk
@@ -1,13 +1,18 @@
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ifndef ENABLE_TESTS
+# We can't package tests if they aren't enabled.
+MOZ_AUTOMATION_PACKAGE_TESTS = 0
+endif
+
ifneq (,$(filter automation/%,$(MAKECMDGOALS)))
ifeq (4.0,$(firstword $(sort 4.0 $(MAKE_VERSION))))
MAKEFLAGS += --output-sync=target
else
.NOTPARALLEL:
endif
endif