| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 * A configuration for running layout tests with testrunner. | 6 * A configuration for running layout tests with testrunner. |
| 7 * This configuration is similar to the interactive_html_config | 7 * This configuration is similar to the interactive_html_config |
| 8 * as it runs each test in its own IFrame. However, where the former | 8 * as it runs each test in its own IFrame. However, where the former |
| 9 * recreated the IFrame for each test, here the IFrames are preserved. | 9 * recreated the IFrame for each test, here the IFrames are preserved. |
| 10 * Furthermore we post a message on completion. | 10 * Furthermore we post a message on completion. |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 234 void onStart() { | 234 void onStart() { |
| 235 // Listen for uncaught errors. | 235 // Listen for uncaught errors. |
| 236 assert(_errorSubscription == null); | 236 assert(_errorSubscription == null); |
| 237 _errorSubscription = window.onError.listen((e) { | 237 _errorSubscription = window.onError.listen((e) { |
| 238 handleExternalError(e, '(DOM callback has errors)'); | 238 handleExternalError(e, '(DOM callback has errors)'); |
| 239 }); | 239 }); |
| 240 | 240 |
| 241 if (!_doneWrap) { | 241 if (!_doneWrap) { |
| 242 _doneWrap = true; | 242 _doneWrap = true; |
| 243 for (int i = 0; i < testCases.length; i++) { | 243 for (int i = 0; i < testCases.length; i++) { |
| 244 testCases[i].test = wrapTest(testCases[i]); | 244 testCases[i].testFunction = wrapTest(testCases[i]); |
| 245 testCases[i].setUp = null; | 245 testCases[i].setUp = null; |
| 246 testCases[i].tearDown = null; | 246 testCases[i].tearDown = null; |
| 247 } | 247 } |
| 248 } | 248 } |
| 249 | 249 |
| 250 _messageSubscription = window.onMessage.listen(_handleMessage); | 250 _messageSubscription = window.onMessage.listen(_handleMessage); |
| 251 } | 251 } |
| 252 | 252 |
| 253 void onTestStart(TestCase testCase) { | 253 void onTestStart(TestCase testCase) { |
| 254 var id = testCase.id; | 254 var id = testCase.id; |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 308 void useHtmlLayoutConfiguration() { | 308 void useHtmlLayoutConfiguration() { |
| 309 if (config != null) return; | 309 if (config != null) return; |
| 310 if (window.location.search == '') { // This is the parent. | 310 if (window.location.search == '') { // This is the parent. |
| 311 _prepareDom(); | 311 _prepareDom(); |
| 312 configure(new ParentHtmlConfiguration()); | 312 configure(new ParentHtmlConfiguration()); |
| 313 } else { | 313 } else { |
| 314 configure(new ChildHtmlConfiguration()); | 314 configure(new ChildHtmlConfiguration()); |
| 315 } | 315 } |
| 316 } | 316 } |
| 317 | 317 |
| OLD | NEW |