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

Side by Side Diff: dart/tools/testing/dart/test_runner.dart

Issue 88443002: Whitelist nonzero content_shell exitcode (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years 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 | Annotate | Revision Log
« 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 /** 5 /**
6 * Classes and methods for executing tests. 6 * Classes and methods for executing tests.
7 * 7 *
8 * This module includes: 8 * This module includes:
9 * - Managing parallel execution of tests, including timeout checks. 9 * - Managing parallel execution of tests, including timeout checks.
10 * - Evaluating the output of each test as pass/fail/crash/timeout. 10 * - Evaluating the output of each test as pass/fail/crash/timeout.
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 if (!isNegative) return outcome; 693 if (!isNegative) return outcome;
694 694
695 if (outcome.canBeOutcomeOf(Expectation.FAIL)) { 695 if (outcome.canBeOutcomeOf(Expectation.FAIL)) {
696 return Expectation.PASS; 696 return Expectation.PASS;
697 } 697 }
698 return Expectation.FAIL; 698 return Expectation.FAIL;
699 } 699 }
700 } 700 }
701 701
702 class BrowserCommandOutputImpl extends CommandOutputImpl { 702 class BrowserCommandOutputImpl extends CommandOutputImpl {
703 // Although tests are reported as passing, content shell sometimes exits with
704 // a nonzero exitcode which makes our dartium builders extremely falky.
705 // See: http://dartbug.com/15139.
706 static int WHITELISTED_CONTENTSHELL_EXITCODE = -1073740022;
707 static bool isWindows = io.Platform.operatingSystem == 'windows';
708
703 bool _failedBecauseOfMissingXDisplay; 709 bool _failedBecauseOfMissingXDisplay;
704 710
705 BrowserCommandOutputImpl( 711 BrowserCommandOutputImpl(
706 command, 712 command,
707 exitCode, 713 exitCode,
708 timedOut, 714 timedOut,
709 stdout, 715 stdout,
710 stderr, 716 stderr,
711 time, 717 time,
712 compilationSkipped) : 718 compilationSkipped) :
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
825 return true; 831 return true;
826 } 832 }
827 assert(containsPass); 833 assert(containsPass);
828 if (exitCode != 0) { 834 if (exitCode != 0) {
829 var message = "All tests passed, but exitCode != 0. " 835 var message = "All tests passed, but exitCode != 0. "
830 "Actual exitcode: $exitCode. " 836 "Actual exitcode: $exitCode. "
831 "($command)"; 837 "($command)";
832 DebugLogger.warning(message); 838 DebugLogger.warning(message);
833 diagnostics.add(message); 839 diagnostics.add(message);
834 } 840 }
835 return (exitCode != 0 && !hasCrashed); 841 return (!hasCrashed &&
842 exitCode != 0 &&
843 (!isWindows || exitCode != WHITELISTED_CONTENTSHELL_EXITCODE));
836 } 844 }
837 DebugLogger.warning("Couldn't find 'Content-Type: text/plain' in output. " 845 DebugLogger.warning("Couldn't find 'Content-Type: text/plain' in output. "
838 "($command)."); 846 "($command).");
839 return true; 847 return true;
840 } 848 }
841 } 849 }
842 850
843 class HTMLBrowserCommandOutputImpl extends BrowserCommandOutputImpl { 851 class HTMLBrowserCommandOutputImpl extends BrowserCommandOutputImpl {
844 HTMLBrowserCommandOutputImpl( 852 HTMLBrowserCommandOutputImpl(
845 command, 853 command,
(...skipping 1549 matching lines...) Expand 10 before | Expand all | Expand 10 after
2395 } 2403 }
2396 } 2404 }
2397 2405
2398 void eventAllTestsDone() { 2406 void eventAllTestsDone() {
2399 for (var listener in _eventListener) { 2407 for (var listener in _eventListener) {
2400 listener.allDone(); 2408 listener.allDone();
2401 } 2409 }
2402 _allDone(); 2410 _allDone();
2403 } 2411 }
2404 } 2412 }
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