# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# 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/.

DIRS += [
    'manifests',
    'tests',
    'ssltunnel',
]

if CONFIG['MOZ_BUILD_APP'] == 'mobile/android':
    DIRS += ['roboextender']

XPI_NAME = 'mochijar'

JAR_MANIFESTS += ['jar.mn']

MOCHITEST_MANIFESTS += [
    'dynamic/mochitest.ini',
    'MochiKit/mochitest.ini',
    'static/mochitest.ini',
    'tests/MochiKit-1.4.2/MochiKit/mochitest.ini',
    'tests/MochiKit-1.4.2/tests/mochitest.ini',
]
MOCHITEST_CHROME_MANIFESTS += ['chrome/chrome.ini']

TEST_HARNESS_FILES.testing.mochitest += [
    '!automation.py',
    '/build/automationutils.py',
    '/build/mobile/remoteautomation.py',
    '/build/pgo/server-locations.txt',
    '/build/sanitizers/lsan_suppressions.txt',
    '/netwerk/test/httpserver/httpd.js',
    '/testing/mozbase/manifestparser/manifestparser/manifestparser.py',
    '/testing/mozbase/mozdevice/mozdevice/devicemanager.py',
    '/testing/mozbase/mozdevice/mozdevice/devicemanagerADB.py',
    '/testing/mozbase/mozdevice/mozdevice/devicemanagerSUT.py',
    '/testing/mozbase/mozdevice/mozdevice/droid.py',
    '/testing/mozbase/mozdevice/mozdevice/Zeroconf.py',
    '/testing/mozbase/moznetwork/moznetwork/moznetwork.py',
    'android.json',
    'android23.json',
    'androidx86.json',
    'b2g_start_script.js',
    'bisection.py',
    'browser-harness.xul',
    'browser-test-overlay.xul',
    'browser-test.js',
    'cc-analyzer.js',
    'chrome-harness.js',
    'chunkifyTests.js',
    'gen_template.pl',
    'gl.json',
    'harness.xul',
    'jetpack-addon-harness.js',
    'jetpack-addon-overlay.xul',
    'jetpack-package-harness.js',
    'jetpack-package-overlay.xul',
    'manifest.webapp',
    'manifestLibrary.js',
    'mochitest_options.py',
    'pywebsocket_wrapper.py',
    'redirect.html',
    'runtests.py',
    'runtestsb2g.py',
    'runtestsremote.py',
    'server.js',
]

if CONFIG['MOZ_BUILD_APP'] == 'mobile/android':
    TEST_HARNESS_FILES.testing.mochitest += [
        '/mobile/android/base/tests/robocop.ini',
        '/mobile/android/base/tests/robocop_autophone.ini',
    ]

TEST_HARNESS_FILES.testing.mochitest.pywebsocket += [
    'pywebsocket/standalone.py',
]

TEST_HARNESS_FILES.testing.mochitest.pywebsocket.mod_pywebsocket += [
    'pywebsocket/mod_pywebsocket/__init__.py',
    'pywebsocket/mod_pywebsocket/_stream_base.py',
    'pywebsocket/mod_pywebsocket/_stream_hixie75.py',
    'pywebsocket/mod_pywebsocket/_stream_hybi.py',
    'pywebsocket/mod_pywebsocket/common.py',
    'pywebsocket/mod_pywebsocket/dispatch.py',
    'pywebsocket/mod_pywebsocket/extensions.py',
    'pywebsocket/mod_pywebsocket/headerparserhandler.py',
    'pywebsocket/mod_pywebsocket/http_header_util.py',
    'pywebsocket/mod_pywebsocket/memorizingfile.py',
    'pywebsocket/mod_pywebsocket/msgutil.py',
    'pywebsocket/mod_pywebsocket/stream.py',
    'pywebsocket/mod_pywebsocket/util.py',
]

TEST_HARNESS_FILES.testing.mochitest.pywebsocket.mod_pywebsocket.handshake += [
    'pywebsocket/mod_pywebsocket/handshake/__init__.py',
    'pywebsocket/mod_pywebsocket/handshake/_base.py',
    'pywebsocket/mod_pywebsocket/handshake/draft75.py',
    'pywebsocket/mod_pywebsocket/handshake/hybi.py',
    'pywebsocket/mod_pywebsocket/handshake/hybi00.py',
]
