| Index: pkg/unittest/lib/test_controller.js
|
| diff --git a/pkg/unittest/lib/test_controller.js b/pkg/unittest/lib/test_controller.js
|
| index 439b7033aea8b4d4a097ec61f907ad8848ba0cc4..d9be055b61ee58c6587dcafac7b5009839731908 100644
|
| --- a/pkg/unittest/lib/test_controller.js
|
| +++ b/pkg/unittest/lib/test_controller.js
|
| @@ -23,7 +23,15 @@ window.onerror = function (message, url, lineNumber) {
|
| window.postMessage('unittest-suite-external-error', '*');
|
| };
|
|
|
| -if (navigator.webkitStartDart) {
|
| +// Start Dartium/content_shell, unless we are waiting for HTML Imports to load.
|
| +// HTML Imports allows a document to link to other HTMLs documents via
|
| +// <link rel=import>. It also allows for those other documents to contain
|
| +// <script> tags, which must be run before scripts on the main page.
|
| +// We have package:html_import to polyfill this feature, and it will handle
|
| +// starting Dartium/content_shell in that case. HTML Imports is used by Polymer,
|
| +// but it could be used by itself too. See the specification:
|
| +// https://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/imports/index.html
|
| +if (navigator.webkitStartDart && !window.HTMLImports) {
|
| navigator.webkitStartDart();
|
| }
|
|
|
|
|