DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Mercurial (409f3966645a)

VCS Links

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123
# -*- Mode: python; 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/.

HAS_MISC_RULE = True

FINAL_TARGET = '_tests/xpcshell/toolkit/mozapps/update/tests/data'

if not CONFIG['MOZ_SUITE']:
  BROWSER_CHROME_MANIFESTS += ['browser/browser.ini']

MOCHITEST_CHROME_MANIFESTS += ['chrome/chrome.ini']

XPCSHELL_TESTS_MANIFESTS += [
    'unit_aus_update/xpcshell.ini',
    'unit_base_updater/xpcshell.ini'
]

if CONFIG['MOZ_MAINTENANCE_SERVICE']:
    XPCSHELL_TESTS_MANIFESTS += ['unit_service_updater/xpcshell.ini']

SimplePrograms([
    'TestAUSHelper',
    'TestAUSReadStrings',
])

LOCAL_INCLUDES += [
    '/toolkit/mozapps/update',
    '/toolkit/mozapps/update/common',
]

if CONFIG['OS_ARCH'] == 'WINNT':
    OS_LIBS += [
        'shlwapi',
      ]

USE_LIBS += [
    'updatecommon',
]

for var in ('MOZ_APP_NAME', 'MOZ_APP_BASENAME', 'MOZ_APP_DISPLAYNAME',
            'MOZ_APP_VENDOR', 'BIN_SUFFIX', 'MOZ_DEBUG'):
    DEFINES[var] = CONFIG[var]

DEFINES['NS_NO_XPCOM'] = True

DisableStlWrapping()

if CONFIG['MOZ_MAINTENANCE_SERVICE']:
    DEFINES['MOZ_MAINTENANCE_SERVICE'] = CONFIG['MOZ_MAINTENANCE_SERVICE']

# For debugging purposes only
#DEFINES['DISABLE_UPDATER_AUTHENTICODE_CHECK'] = True

if CONFIG['OS_ARCH'] == 'WINNT':
    DEFINES['UNICODE'] = True
    DEFINES['_UNICODE'] = True
    USE_STATIC_LIBS = True
    if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
        WIN32_EXE_LDFLAGS += ['-municode']

TEST_HARNESS_FILES.testing.mochitest.browser.toolkit.mozapps.update.tests.browser += [
    'chrome/update.sjs',
    'data/shared.js',
    'data/sharedUpdateXML.js',
    'data/simple.mar',
]

TEST_HARNESS_FILES.testing.mochitest.chrome.toolkit.mozapps.update.tests.data += [
    'data/shared.js',
    'data/sharedUpdateXML.js',
    'data/simple.mar',
]

FINAL_TARGET_FILES += [
    'data/complete.exe',
    'data/complete.mar',
    'data/complete.png',
    'data/complete_log_success_mac',
    'data/complete_log_success_win',
    'data/complete_mac.mar',
    'data/complete_precomplete',
    'data/complete_precomplete_mac',
    'data/complete_removed-files',
    'data/complete_removed-files_mac',
    'data/complete_update_manifest',
    'data/old_version.mar',
    'data/partial.exe',
    'data/partial.mar',
    'data/partial.png',
    'data/partial_log_failure_mac',
    'data/partial_log_failure_win',
    'data/partial_log_success_mac',
    'data/partial_log_success_win',
    'data/partial_mac.mar',
    'data/partial_precomplete',
    'data/partial_precomplete_mac',
    'data/partial_removed-files',
    'data/partial_removed-files_mac',
    'data/partial_update_manifest',
    'data/replace_log_success',
    'data/shared.js',
    'data/sharedUpdateXML.js',
    'data/simple.mar',
    'data/wrong_product_channel.mar',
    'data/xpcshellUtilsAUS.js',
    'TestAUSReadStrings1.ini',
    'TestAUSReadStrings2.ini',
    'TestAUSReadStrings3.ini',
]

FINAL_TARGET_PP_FILES += [
    'data/xpcshellConstantsPP.js',
]

with Files("browser/browser_TelemetryUpdatePing.js"):
    BUG_COMPONENT = ("Toolkit", "Telemetry")

if CONFIG['CC_TYPE'] == 'gcc':
    CXXFLAGS += ['-Wno-format-truncation']