OLD | NEW |
1 <html> | 1 <html> |
2 <link rel="import" href="../resources/dump-as-text.sky" /> | 2 <import src="../resources/dump-as-text.sky" /> |
3 <link rel="import" href="../resources/chai.sky" /> | 3 <import src="../resources/chai.sky" /> |
4 <body> | 4 <body> |
5 This test ensures that the lifecycle callback of a parser-made element is visibl
e in following script block. | 5 This test ensures that the lifecycle callback of a parser-made element is visibl
e in following script block. |
6 <script> | 6 <script> |
7 var proto = Object.create(HTMLElement.prototype, { createdCallback: { value: fun
ction() { window.callbacksCalled = true; } } }); | 7 var proto = Object.create(HTMLElement.prototype, { createdCallback: { value: fun
ction() { window.callbacksCalled = true; } } }); |
8 document.registerElement("x-foo", { prototype: proto }); | 8 document.registerElement("x-foo", { prototype: proto }); |
9 </script> | 9 </script> |
10 <x-foo></x-foo> | 10 <x-foo></x-foo> |
11 <script> | 11 <script> |
12 assert.ok("window.callbacksCalled"); | 12 assert.ok("window.callbacksCalled"); |
13 </script> | 13 </script> |
14 </body> | 14 </body> |
15 </html> | 15 </html> |
OLD | NEW |