| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <style> | 2 <style> |
| 3 .run { | 3 .run { |
| 4 animation: foo 1s infinite alternate; | 4 animation: foo 1s infinite alternate; |
| 5 } | 5 } |
| 6 | 6 |
| 7 @keyframes foo { | 7 @keyframes foo { |
| 8 100% { | 8 100% { |
| 9 transform: translateX(100px) | 9 transform: translateX(100px) |
| 10 } | 10 } |
| 11 } | 11 } |
| 12 </style> | 12 </style> |
| 13 <div id="target"></div> | 13 <div id="target"></div> |
| 14 <script src="../resources/testharness.js"></script> | 14 <script src="../../resources/testharness.js"></script> |
| 15 <script src="../resources/testharnessreport.js"></script> | 15 <script src="../../resources/testharnessreport.js"></script> |
| 16 <script> | 16 <script> |
| 17 var test = async_test('Race between visibility and set compositor pending should
not crash'); | 17 var test = async_test('Race between visibility and set compositor pending should
not crash'); |
| 18 requestAnimationFrame(t => { | 18 requestAnimationFrame(t => { |
| 19 requestAnimationFrame(t => { | 19 requestAnimationFrame(t => { |
| 20 target.classList.add('run'); | 20 target.classList.add('run'); |
| 21 setTimeout(() => { | 21 setTimeout(() => { |
| 22 testRunner.setPageVisibility("hidden"); | 22 testRunner.setPageVisibility("hidden"); |
| 23 target.style.transform = 'translateX(50px)'; | 23 target.style.transform = 'translateX(50px)'; |
| 24 target.offsetTop; | 24 target.offsetTop; |
| 25 setTimeout(() => { | 25 setTimeout(() => { |
| 26 test.done(); | 26 test.done(); |
| 27 }, 0); | 27 }, 0); |
| 28 }, 0); | 28 }, 0); |
| 29 }); | 29 }); |
| 30 }); | 30 }); |
| 31 </script> | 31 </script> |
| OLD | NEW |