Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / web-animations-api / animations-responsive-backgroundPosition.html
blobd9b46bdd5abdb19d80fc374fdc1a17bd7bfcdc3f
1 <!DOCTYPE html>
2 <script src="../resources/testharness.js"></script>
3 <script src="../resources/testharnessreport.js"></script>
5 <div id='container'>
6 <div id='element'></div>
7 </div>
9 <script>
10 var element = document.getElementById('element');
11 var container = document.getElementById('container');
13 test(function() {
14 element.style.fontSize = '10px';
15 var player = element.animate([
16 {backgroundPosition: '10% 1em'},
17 {backgroundPosition: '20% 5em'}],
18 10);
19 player.pause();
20 player.currentTime = 5;
21 element.style.fontSize = '20px';
22 assert_equals(getComputedStyle(element).backgroundPosition, '15% 60px');
23 }, 'Background position responsive to style changes');
25 </script>