author Dave Townsend <>
Mon, 22 Sep 2014 11:08:06 -0700
changeset 206459 1401f98a790e4c02254f0ce61c027acc41930548
parent 204685 1a6883cb1a09a291fae072e219f86f53f41c05e5
child 217595 d37c4d4a351dd813fdc3c15b63faf44401736412
permissions -rw-r--r--
Bug 1035512: Add a new common JS testing harness based on the mochitest test runner. r=gps, ted, erikvold, jmaher

# 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

TESTADDONS = source/test/addons
TESTROOT = $(CURDIR)/$(DEPTH)/_tests/testing/mochitest/jetpack-addon/$(relativesrcdir)/$(TESTADDONS)

# Build a list of the test add-ons
ADDONS = $(patsubst $(ADDONSRC)/%/package.json,$(TESTADDONS)/%.xpi,$(wildcard $(ADDONSRC)/*/package.json))

INSTALL_TARGETS += test_addons
test_addons_FILES = $(ADDONS)
test_addons_DEST = $(TESTROOT)

sinclude $(topsrcdir)/config/

# This can switch to just zipping the files when native jetpacks land
$(TESTADDONS)/%.xpi: FORCE $(call mkdir_deps,$(CURDIR)/$(TESTADDONS)) $(ADDONSRC)/%
	$(PYTHON) $(srcdir)/source/bin/cfx xpi --pkgdir=$(lastword $^) --output-file=$@

#libs:: $(ADDONS)

  $(srcdir)/source/app-extension \
  $(srcdir)/source/bin \
  $(srcdir)/source/python-lib \
  $(srcdir)/source/test \
  $(srcdir)/source/package.json \
  $(srcdir)/source/mapping.json \

# Remove this once the test harness uses the APIs built into Firefox
TEST_FILES += $(srcdir)/source/lib

PKG_STAGE = $(DIST)/test-stage

stage-tests-package:: $(TEST_FILES)
	$(INSTALL) $^ $(PKG_STAGE)/jetpack