Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(244)

Side by Side Diff: lib/src/runner/browser/firefox.dart

Issue 1090333003: Disable crash reporting on Firefox. (Closed) Base URL: git@github.com:dart-lang/test@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library test.runner.browser.firefox; 5 library test.runner.browser.firefox;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:io'; 8 import 'dart:io';
9 9
10 import 'package:path/path.dart' as p; 10 import 'package:path/path.dart' as p;
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 withTempDir((dir) { 58 withTempDir((dir) {
59 _dir = dir; 59 _dir = dir;
60 60
61 new File(p.join(dir, 'prefs.js')).writeAsStringSync(_preferences); 61 new File(p.join(dir, 'prefs.js')).writeAsStringSync(_preferences);
62 62
63 return Process.start(executable, [ 63 return Process.start(executable, [
64 "--profile", 64 "--profile",
65 "$_dir", 65 "$_dir",
66 url.toString(), 66 url.toString(),
67 "--no-remote" 67 "--no-remote"
68 ]).then((process) { 68 ], environment: {
69 "MOZ_CRASHREPORTER_DISABLE": "1"
70 }).then((process) {
69 _process = process; 71 _process = process;
70 _onProcessStartedCompleter.complete(); 72 _onProcessStartedCompleter.complete();
71 73
72 // TODO(nweiz): the browser's standard output is almost always useless 74 // TODO(nweiz): the browser's standard output is almost always useless
73 // noise, but we should allow the user to opt in to seeing it. 75 // noise, but we should allow the user to opt in to seeing it.
74 return _process.exitCode; 76 return _process.exitCode;
75 }); 77 });
76 }).then((exitCode) { 78 }).then((exitCode) {
77 if (exitCode != 0) throw "Firefox failed with exit code $exitCode."; 79 if (exitCode != 0) throw "Firefox failed with exit code $exitCode.";
78 }).then(_onExitCompleter.complete) 80 }).then(_onExitCompleter.complete)
(...skipping 27 matching lines...) Expand all
106 108
107 var path = p.join(prefix, suffix); 109 var path = p.join(prefix, suffix);
108 if (new File(p.join(prefix, suffix)).existsSync()) return path; 110 if (new File(p.join(prefix, suffix)).existsSync()) return path;
109 } 111 }
110 112
111 // Fall back on looking it up on the path. This probably won't work, but at 113 // Fall back on looking it up on the path. This probably won't work, but at
112 // least it will fail with a useful error message. 114 // least it will fail with a useful error message.
113 return "firefox.exe"; 115 return "firefox.exe";
114 } 116 }
115 } 117 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698