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

Unified Diff: tools/testing/dart/test_runner.dart

Issue 9641003: Example of deadlock in test_runner.dart on process crash (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « compiler/java/com/google/dart/compiler/type/TypeAnalyzer.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/dart/test_runner.dart
diff --git a/tools/testing/dart/test_runner.dart b/tools/testing/dart/test_runner.dart
index d3c97e120ff8a83775c6a784639b05e0695b601d..15c4c95e718dbd51cb210960fc2d76c47574a4bb 100644
--- a/tools/testing/dart/test_runner.dart
+++ b/tools/testing/dart/test_runner.dart
@@ -671,6 +671,7 @@ class BatchRunnerProcess {
}
int _reportResult(String output) {
+ print ("_stdoutDrained: ${_currentTest.displayName}");
_stdoutDrained = true;
// output = '>>> TEST {PASS, FAIL, OK, CRASH, FAIL, TIMEOUT}'
var outcome = output.split(" ")[2];
@@ -684,6 +685,7 @@ class BatchRunnerProcess {
}
void _stderrDone() {
+ print ("_stdoutDrained: ${_currentTest.displayName}");
_stderrDrained = true;
// Move on when both stdout and stderr has been drained.
if (_stdoutDrained) _testCompleted();
@@ -732,6 +734,9 @@ class BatchRunnerProcess {
void _exitHandler(exitCode) {
if (_timer != null) _timer.cancel();
_process.close();
+ if (!(_stdoutDrained && stderrDrained)) {
+ print("*** POTENTIAL DEADLOCK on process restart");
+ }
_startProcess(() {
_reportResult(">>> TEST CRASH");
});
« no previous file with comments | « compiler/java/com/google/dart/compiler/type/TypeAnalyzer.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698