2011-04-25 Simon Fraser <simon.fraser@apple.com>
[WebKit-https.git] / LayoutTests / transitions / transition-duration-cleared-in-transitionend-crash.html
1 <html>
2     <body>
3         This tests that we don't crash if we clear a transitions duration during the transition end callback.
4         <div id="t" style="background-color:#000">test</div> 
5         <script>
6             if (window.layoutTestController) {
7                 layoutTestController.dumpAsText();
8                 layoutTestController.waitUntilDone();
9             }
10             var el = document.getElementById('t');
11             el.addEventListener('webkitTransitionEnd', function(){
12                 el.style.webkitTransitionDuration = '';
13                 if (window.layoutTestController)
14                     layoutTestController.notifyDone();
15             });
16             el.style.cssText += ';-webkit-transition:background-color 0.2s;background-color:#fff'
17         </script>
18     </body>
19 </html>