OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script src="../../resources/js-test.js"></script> | 4 <script src="../../resources/js-test.js"></script> |
5 </head> | 5 </head> |
6 <body> | 6 <body> |
7 <script> | 7 <script> |
8 description('Unittests for private scripts.'); | 8 description('Unittests for private scripts.'); |
9 if (internals) | 9 if (internals) |
10 debug('This test needs window.internals.'); | 10 debug('This test needs window.internals.'); |
(...skipping 31 matching lines...) Loading... |
42 shouldBeEqualToString('internals.innerHTML(node5)', '<div>foo</div>') | 42 shouldBeEqualToString('internals.innerHTML(node5)', '<div>foo</div>') |
43 var node6 = internals.firstChild(node5); | 43 var node6 = internals.firstChild(node5); |
44 shouldBeEqualToString('internals.innerHTML(node6)', 'foo'); | 44 shouldBeEqualToString('internals.innerHTML(node6)', 'foo'); |
45 | 45 |
46 var node7 = internals.createElement(document); | 46 var node7 = internals.createElement(document); |
47 shouldBeEqualToString('internals.innerHTML(node7)', '') | 47 shouldBeEqualToString('internals.innerHTML(node7)', '') |
48 internals.addClickListener(node7); | 48 internals.addClickListener(node7); |
49 internals.clickNode(document, node7); | 49 internals.clickNode(document, node7); |
50 shouldBeEqualToString('internals.innerHTML(node7)', 'clicked') | 50 shouldBeEqualToString('internals.innerHTML(node7)', 'clicked') |
51 | 51 |
| 52 shouldBe('internals.readonlyShortAttribute', '123'); |
| 53 shouldBe('internals.shortAttribute', '-1'); |
| 54 internals.shortAttribute = 111; |
| 55 shouldBe('internals.shortAttribute', '111'); |
| 56 shouldBeEqualToString('internals.stringAttribute', 'xxx'); |
| 57 internals.stringAttribute = "foo"; |
| 58 shouldBeEqualToString('internals.stringAttribute', 'foo'); |
| 59 shouldBe('internals.nodeAttribute', 'null'); |
| 60 var node8 = internals.createElement(document); |
| 61 internals.nodeAttribute = node8; |
| 62 shouldBe('internals.nodeAttribute', 'node8'); |
| 63 |
52 </script> | 64 </script> |
53 </body> | 65 </body> |
54 </html> | 66 </html> |
OLD | NEW |