| OLD | NEW |
| (Empty) | |
| 1 <!DOCTYPE html> |
| 2 <style> |
| 3 div { |
| 4 margin-bottom: 20px; |
| 5 width: 100px; |
| 6 height: 100px; |
| 7 } |
| 8 .background-and-shadow { |
| 9 background-color: blue; |
| 10 /* The image is 1x1 lime */ |
| 11 background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABC
AIAAACQd1PeAAAADElEQVQI12Ng+M8AAAICAQCqKp4nAAAAAElFTkSuQmCC'); |
| 12 box-shadow: 0 10px black; |
| 13 } |
| 14 </style> |
| 15 Tests background color/image and shadow painting with static and dynamic style. |
| 16 Passes if there are two green squares with black shadows. |
| 17 <div class="background-and-shadow"></div> |
| 18 <div id="target"></div> |
| 19 <script> |
| 20 function test() { |
| 21 // Apply background and shadow styles to target after the image has |
| 22 // been loaded and decoded, to test the dynamic behavior. |
| 23 target.className = 'background-and-shadow'; |
| 24 if (window.testRunner) |
| 25 testRunner.notifyDone(); |
| 26 } |
| 27 |
| 28 if (window.testRunner) { |
| 29 testRunner.waitUntilDone(); |
| 30 testRunner.capturePixelsAsyncThen(test); |
| 31 } else { |
| 32 setTimeout(test, 500); |
| 33 } |
| 34 </script> |
| OLD | NEW |