Bug 1380402 - Set MOZ_DEVELOPER_REPO_DIR in the environment when running TPS on mac. r?markh
MozReview-Commit-ID: 2jtresePxiu
--- a/testing/tps/tps/cli.py
+++ b/testing/tps/tps/cli.py
@@ -101,16 +101,20 @@ def main():
'services', 'sync', 'tps', 'extensions')
else:
if sys.platform == 'win32':
# replace msys-style paths with proper Windows paths
m = re.match('^\/\w\/', extensionDir)
if m:
extensionDir = '%s:/%s' % (m.group(0)[1:2], extensionDir[3:])
extensionDir = extensionDir.replace('/', '\\')
+ if sys.platform == 'darwin':
+ # Needed to avoid tab crashes on mac due to level 3 sandboxing
+ sourceRoot = os.path.join(extensionDir, '..', '..', '..', '..')
+ os.environ['MOZ_DEVELOPER_REPO_DIR'] = os.path.abspath(sourceRoot)
TPS = TPSTestRunner(extensionDir,
binary=options.binary,
config=config,
debug=options.debug,
ignore_unused_engines=options.ignore_unused_engines,
logfile=options.logfile,
mobile=options.mobile,