aboutsummaryrefslogtreecommitdiffstats
path: root/tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html
diff options
context:
space:
mode:
authorWPT Sync Bot <josh+wptsync@joshmatthews.net>2020-10-21 08:19:33 +0000
committerWPT Sync Bot <josh+wptsync@joshmatthews.net>2020-10-21 10:33:31 +0000
commit5097f12054f9f20280be856622d905b5cec307f9 (patch)
treef10295d16a14a4b178d6b61ffedf7a7b86d59932 /tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html
parent1d217b7f0f95a5f5629ee6c9b5ca57319232a509 (diff)
downloadservo-5097f12054f9f20280be856622d905b5cec307f9.tar.gz
servo-5097f12054f9f20280be856622d905b5cec307f9.zip
Update web-platform-tests to revision 0a45e9baf952da4787f81ca93d34dfad3ca24d33
Diffstat (limited to 'tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html')
-rw-r--r--tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html64
1 files changed, 64 insertions, 0 deletions
diff --git a/tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html b/tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html
new file mode 100644
index 00000000000..d9c87a34a53
--- /dev/null
+++ b/tests/wpt/web-platform-tests/css/css-overflow/overflow-clip-margin-invalidation.html
@@ -0,0 +1,64 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+<head>
+<title>CSS Overflow: overflow-clip-margin: invalidation on change</title>
+<link rel="help" href="https://www.w3.org/TR/css-overflow-3/#propdef-overflow-clip-margin">
+<meta name="assert" content="overflow-clip-margin: toggling should invalidate.">
+<link rel="author" title="Scott Violet" href="mailto:sky@chromium.org">
+<link rel="match" href="overflow-clip-margin-invalidation-ref.html">
+<style>
+ .container {
+ display: flex;
+ }
+ .parent {
+ flex: none;
+ width: 100px;
+ height: 100px;
+ flex: none;
+ overflow: clip;
+ }
+ .child {
+ width: 200px;
+ height: 200px;
+ position: relative;
+ top: -50px;
+ left: -50px;
+ background-color: green;
+ }
+ .spacer {
+ flex: none;
+ height: 100px;
+ width: 100px;
+ }
+ .margin {
+ overflow-clip-margin: 10px;
+ }
+</style>
+<script src="/common/reftest-wait.js"></script>
+<script src="/common/rendering-utils.js"></script>
+</head>
+<body>
+<div class="spacer"></div>
+<div class="container">
+ <div class="spacer"></div>
+ <div id="div_with_margin" class="parent margin">
+ <div class="child"></div>
+ </div>
+<div class="spacer"></div>
+<div class="container">
+ <div class="spacer"></div>
+ <div id="div_without_margin" class="parent">
+ <div class="child"></div>
+ </div>
+</body>
+<script>
+async function runTest() {
+ document.getElementById('div_with_margin').classList.remove("margin");
+ document.getElementById('div_without_margin').classList.add("margin");
+ takeScreenshot();
+}
+onload = () => {
+ waitForAtLeastOneFrame().then(() => { runTest() });
+}
+</script>
+</html>