Bug 1440719 - Set MOZ_CRASHREPORTER_SHUTDOWN during tests, other than browser-chrome; r=ted
☠☠ backed out by 43f4672c5ca3 ☠ ☠
authorGeoff Brown <gbrown@mozilla.com>
Wed, 07 Mar 2018 10:18:40 -0700
changeset 407072 1383d36fdabf8b134973bc15b69587d2e74e9d8a
parent 407024 97d8b867071938df9e8e2126d986ea348f55c649
child 407073 b87c9f3e9d5d314b553cd411a1554fa7cd11528f
push id33589
push usercsabou@mozilla.com
push dateThu, 08 Mar 2018 03:59:55 +0000
treeherdermozilla-central@888f3dded126 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted
bugs1440719
milestone60.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1440719 - Set MOZ_CRASHREPORTER_SHUTDOWN during tests, other than browser-chrome; r=ted
build/mobile/remoteautomation.py
testing/mochitest/runtests.py
testing/mozbase/mozrunner/mozrunner/utils.py
--- a/build/mobile/remoteautomation.py
+++ b/build/mobile/remoteautomation.py
@@ -60,16 +60,17 @@ class RemoteAutomation(Automation):
         # passed to runtestsremote.py as an actual option, but through the
         # MOZ_HIDE_RESULTS_TABLE environment variable.
         if 'MOZ_HIDE_RESULTS_TABLE' in os.environ:
             env['MOZ_HIDE_RESULTS_TABLE'] = os.environ['MOZ_HIDE_RESULTS_TABLE']
 
         if crashreporter and not debugger:
             env['MOZ_CRASHREPORTER_NO_REPORT'] = '1'
             env['MOZ_CRASHREPORTER'] = '1'
+            env['MOZ_CRASHREPORTER_SHUTDOWN'] = '1'
         else:
             env['MOZ_CRASHREPORTER_DISABLE'] = '1'
 
         # Crash on non-local network connections by default.
         # MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
         # enable non-local connections for the purposes of local testing.
         # Don't override the user's choice here.  See bug 1049688.
         env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')
--- a/testing/mochitest/runtests.py
+++ b/testing/mochitest/runtests.py
@@ -1644,16 +1644,21 @@ toolbar#nav-bar {
             browserEnv["MOZ_DEVELOPER_OBJ_DIR"] = options.topobjdir
 
         if options.headless:
             browserEnv["MOZ_HEADLESS"] = '1'
 
         if options.dmd:
             browserEnv["DMD"] = os.environ.get('DMD', '1')
 
+        # bug 1443327: do not set MOZ_CRASHREPORTER_SHUTDOWN during browser-chrome
+        # tests, since some browser-chrome tests test content process crashes
+        if options.flavor == 'browser':
+            del browserEnv["MOZ_CRASHREPORTER_SHUTDOWN"]
+
         # These variables are necessary for correct application startup; change
         # via the commandline at your own risk.
         browserEnv["XPCOM_DEBUG_BREAK"] = "stack"
 
         # interpolate environment passed with options
         try:
             browserEnv.update(
                 dict(
--- a/testing/mozbase/mozrunner/mozrunner/utils.py
+++ b/testing/mozbase/mozrunner/mozrunner/utils.py
@@ -116,16 +116,17 @@ def test_environment(xrePath, env=None, 
 
     # crashreporter
     env['GNOME_DISABLE_CRASH_DIALOG'] = '1'
     env['XRE_NO_WINDOWS_CRASH_DIALOG'] = '1'
 
     if crashreporter and not debugger:
         env['MOZ_CRASHREPORTER_NO_REPORT'] = '1'
         env['MOZ_CRASHREPORTER'] = '1'
+        env['MOZ_CRASHREPORTER_SHUTDOWN'] = '1'
     else:
         env['MOZ_CRASHREPORTER_DISABLE'] = '1'
 
     # Crash on non-local network connections by default.
     # MOZ_DISABLE_NONLOCAL_CONNECTIONS can be set to "0" to temporarily
     # enable non-local connections for the purposes of local testing.  Don't
     # override the user's choice here.  See bug 1049688.
     env.setdefault('MOZ_DISABLE_NONLOCAL_CONNECTIONS', '1')