Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!DOCTYPE html> | |
| 2 <script src="../../resources/testharness.js"></script> | |
| 3 <script src="../../resources/testharnessreport.js"></script> | |
| 4 <script> | |
| 5 'use strict'; | |
| 6 | |
| 7 let reactions = []; | |
| 8 </script> | |
| 9 <x-x id="a"></x-x> | |
| 10 <y-y id="x"></y-y> | |
| 11 <link id="import1" rel="import" href="resources/upgrade.html"> | |
| 12 <x-x id="b"></x-x> | |
| 13 <y-y id="y"></y-y> | |
| 14 <script> | |
| 15 'use strict' | |
| 16 | |
| 17 async_test((test) => { | |
| 18 window.onload = test.step_func_done(() => { | |
| 19 customElements.define('y-y', class extends HTMLElement { | |
| 20 constructor() { | |
| 21 super(); | |
|
tkent
2016/08/24 12:07:20
wrong indentation.
kochi
2016/08/24 15:36:51
Done.
| |
| 22 reactions.push({ type: 'constructor', element: this }); | |
| 23 } | |
| 24 }); | |
| 25 | |
| 26 let elements = reactions.map(e => e.element.id); | |
| 27 assert_array_equals(elements, ['a', 'aa', 'b', 'x', 'bb', 'y']); | |
| 28 }, 'Upgrade of custom elements should happen in document order.'); | |
| 29 }); | |
| 30 </script> | |
| OLD | NEW |