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

Unified Diff: tools/testing/architecture.py

Issue 8525005: Defer further starting timeout watch dog. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years, 1 month 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 | « client/tests/client/client.status ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/testing/architecture.py
diff --git a/tools/testing/architecture.py b/tools/testing/architecture.py
index 816d4319035a6e57b6afeabdbbfe0396e556b14b..905eca35a0845036e60475b25c439367fbb3dcba 100755
--- a/tools/testing/architecture.py
+++ b/tools/testing/architecture.py
@@ -32,9 +32,10 @@ HTML_CONTENTS = """
<script type="%(script_type)s" src="%(source_script)s"></script>
<script type="text/javascript">
// If nobody intercepts the error, finish the test.
- window.onerror = function() { window.layoutTestController.notifyDone() };
+ onerror = function() { window.layoutTestController.notifyDone() };
- window.addEventListener('DOMContentLoaded', function() {
+ document.onreadystatechange = function() {
+ if (document.readyState != "loaded") return;
// If 'startedDartTest' is not set, that means that the test did not have
// a chance to load. This will happen when a load error occurs in the VM.
// Give the machine time to start up.
@@ -43,13 +44,12 @@ HTML_CONTENTS = """
// Just sleep another time to give the browser the time to process the
// posted message.
setTimeout(function() {
- if (window.layoutTestController
- && !window.layoutTestController.startedDartTest) {
- window.layoutTestController.notifyDone();
+ if (layoutTestController && !layoutTestController.startedDartTest) {
+ layoutTestController.notifyDone();
}
}, 0);
}, 50);
- }, false);
+ };
</script>
</body>
</html>
« no previous file with comments | « client/tests/client/client.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698