Refactoring: Pull all fullscreen code out of Document and into its own helper class
[WebKit-https.git] / LayoutTests / transitions / lengthsize-transition-to-from-auto.html
1 <!DOCTYPE html>
2
3 <html>
4 <head>
5   <style>
6     .box {
7         position: relative;
8         height: 100px;
9         width: 100px;
10         margin: 10px;
11         background-color: gray;
12         background-image: url('../fast/backgrounds/repeat/resources/gradient.gif');
13         transition: background-size 2s linear;
14     }
15     
16     #test1 {
17         background-size: 10px 10px;
18     }
19     
20     body.final #test1 {
21         background-size: 100px 10px;
22     }
23
24     #test2 {
25         background-size: auto 10px;
26     }
27     
28     body.final #test2 {
29         background-size: 10px auto;
30     }
31
32     #test3 {
33         background-size: auto auto;
34     }
35     
36     body.final #test3 {
37         background-size: 10px 10px;
38     }
39   </style>
40   <script src="resources/transition-test-helpers.js"></script>
41   <script type="text/javascript">
42
43     const expectedValues = [
44       // [time, element-id, property, expected-value, tolerance]
45       [1, 'test1', 'background-size', [55, 10], 2],
46       [1, 'test2', 'background-size', [10], 2],
47       [1, 'test3', 'background-size', [10,10], 2],
48     ];
49   
50     function setupTest()
51     {
52         document.body.classList.add('final');
53     }
54     
55     runTransitionTest(expectedValues, setupTest, usePauseAPI);
56   </script>
57 </head>
58 <body>
59   <div id="test1" class="box"></div>
60   <div id="test2" class="box"></div>
61   <div id="test3" class="box"></div>
62
63   <div id="result"></div>
64 </body>
65 </html>