mailnews/Makefile.in
author Joshua Cranmer <Pidgeot18@gmail.com>
Mon, 18 Nov 2013 21:08:17 -0600
changeset 16910 dda8c42d23a8ad0b4de949083b0faf11be92e5cf
parent 16356 e151863035fe256051297ec9981de9cbcaf17815
child 16925 0fef4c10f850ccba2794cbb08991741922a06644
permissions -rw-r--r--
Port bug 939044 to comm-central, rs=bustage-fix This involves deleting unused MODULE declarations and renaming others to XPIDL_MODULE. Also, pushing to SeaMonkey's CLOSED TREE.

#
# 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/.

DEPTH		= @DEPTH@
topsrcdir	= @top_srcdir@
srcdir		= @srcdir@
VPATH		= @srcdir@

include $(DEPTH)/config/autoconf.mk

PREF_JS_EXPORTS = $(srcdir)/mailnews.js

DEFINES += -DOS_ARCH=$(OS_ARCH) \
           -DMOZ_WIDGET_TOOLKIT=$(MOZ_WIDGET_TOOLKIT) \
           -DNO_NSPR_10_SUPPORT \
           $(NULL)

ifdef ENABLE_TESTS
RESDIR = $(srcdir)/test/resources
FAKESERVER := $(srcdir)/test/fakeserver
TESTING_JS_MODULE_DIR = mailnews
TESTING_JS_MODULES += \
	$(RESDIR)/IMAPpump.js \
	$(RESDIR)/localAccountUtils.js \
	$(RESDIR)/mailTestUtils.js \
	$(FAKESERVER)/auth.js \
	$(FAKESERVER)/imapd.js \
	$(FAKESERVER)/maild.js \
	$(FAKESERVER)/nntpd.js \
	$(FAKESERVER)/pop3d.js \
	$(FAKESERVER)/smtpd.js \
	$(NULL)
endif

include $(topsrcdir)/config/rules.mk

ifdef ENABLE_TESTS
libs::
	$(INSTALL) $(wildcard $(srcdir)/test/resources/*.js) $(MOZDEPTH)/_tests/xpcshell/mailnews/resources
	$(INSTALL) $(wildcard $(srcdir)/test/data/*) $(MOZDEPTH)/_tests/xpcshell/mailnews/data

# We provide an xpcshell-tests target here because the top-level target acts
# differently to the specific directory one. We want our developers to be able
# to run "make -C mailnews xpcshell-tests" so we do this short-cut here. This
# list is kept in the same order as the effective DIRS just so things turn up
# in the same order as the build.

XPCSHELL_TEST_DIRS = addrbook base compose db/gloda db/msgdb extensions/bayesian-spam-filter extensions/mdn imap import local mime news

xpcshell-tests::
	$(PYTHON) -u $(MOZILLA_DIR)/config/pythonpath.py \
	  -I$(MOZDEPTH)/build \
	  -I$(MOZILLA_DIR)/build -I$(MOZDEPTH)/_tests/mozbase/mozinfo \
	  $(MOZILLA_SRCDIR)/testing/xpcshell/runxpcshelltests.py \
	  --symbols-path=$(DIST)/crashreporter-symbols \
	  --build-info-json=$(MOZDEPTH)/mozinfo.json \
	  --tests-root-dir=$(testxpcobjdir) \
          --testing-modules-dir=$(MOZDEPTH)/_tests/modules \
	  --xunit-file=$(testxpcobjdir)/mailnews/results.xml \
	  --xunit-suite-name=xpcshell \
	  $(EXTRA_TEST_ARGS) \
	  $(LIBXUL_DIST)/bin/xpcshell \
	  $(foreach dir,$(XPCSHELL_TEST_DIRS),$(testxpcobjdir)/mailnews/$(dir)/test/unit)
endif