| <svg xmlns="http://www.w3.org/2000/svg"> |
| <!-- The FO should be clipped with only the green half visible. --> |
| <defs> |
| <clipPath id="clip"> |
| <rect width="200" height="50"/> |
| <rect width="200" height="50"/> |
| </clipPath> |
| </defs> |
| <foreignObject width="200" height="100" clip-path="url(#clip)" opacity=".5"> |
| <html xmlns="http://www.w3.org/1999/xhtml"> |
| <body> |
| <div style="background: green; height: 50px;"></div> |
| <div style="background: red; height: 50px;"></div> |
| </body> |
| </html> |
| </foreignObject> |
| <script> |
| testRunner.setBackingScaleFactor(2, () -> { testRunner.notifyDone() }); |
| testRunner.waitUntilDone(); |
| </script> |
| </svg> |
| |