OLD | NEW |
1 <!DOCTYPE HTML> | 1 <!DOCTYPE HTML> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <title>Test for WebKit bug 31559: Crash with mismatched lists and shorthands.</t
itle> | 4 <title>Test for WebKit bug 31559: Crash with mismatched lists and shorthands.</t
itle> |
5 <script src="../js/resources/js-test-pre.js"></script> | 5 <script src="../js/resources/js-test-pre.js"></script> |
6 </head> | 6 </head> |
7 <body> | 7 <body> |
8 <p id="description">Test for WebKit bug <a href="https://bugs.webkit.org/show_
bug.cgi?id=31559">31559</a>: Crash with mismatched lists and shorthands.</p> | 8 <p id="description">Test for WebKit bug <a href="https://bugs.webkit.org/show_
bug.cgi?id=31559">31559</a>: Crash with mismatched lists and shorthands.</p> |
9 <div id="console"></div> | 9 <div id="console"></div> |
10 | 10 |
11 <div id="test"></div> | 11 <div id="test"></div> |
12 | 12 |
13 <script> | 13 <script> |
14 var para = document.getElementById('test'); | 14 var para = document.getElementById('test'); |
15 | 15 |
16 // Test longer shorthand | 16 // Test longer shorthand |
17 para.style.webkitTransition = 'width 1s, left 1s, top 1s'; | 17 para.style.webkitTransition = 'width 1s, left 1s, top 1s'; |
18 para.style.webkitTransitionProperty = 'width, left'; | 18 para.style.webkitTransitionProperty = 'width, left'; |
19 | 19 |
20 shouldBeEqualToString("para.style.webkitTransition", "width 1s, left 1s, 1s"); | 20 shouldBeEqualToString("para.style.webkitTransition", "width 1s, left 1s, 1s"); |
21 | 21 |
22 // Test shorter shorthand | 22 // Test shorter shorthand |
23 para.style.webkitTransition = 'width 1s, left 1s'; | 23 para.style.webkitTransition = 'width 1s, left 1s'; |
24 para.style.webkitTransitionProperty = 'width, left, top'; | 24 para.style.webkitTransitionProperty = 'width, left, top'; |
25 | 25 |
26 // the next line will crash | 26 // the next line will crash |
27 shouldBeEqualToString("para.style.webkitTransition", "width 1s, left 1s, top")
; | 27 shouldBeEqualToString("para.style.webkitTransition", "width 1s, left 1s, top")
; |
28 </script> | 28 </script> |
29 <script src="../js/resources/js-test-post.js"></script> | |
30 </body> | 29 </body> |
31 </html> | 30 </html> |
OLD | NEW |