| Index: third_party/WebKit/LayoutTests/fast/css/invalidation/rule-change.html
|
| diff --git a/third_party/WebKit/LayoutTests/fast/css/invalidation/rule-change.html b/third_party/WebKit/LayoutTests/fast/css/invalidation/rule-change.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..5684f4f5ae6729c9c1cae9e12fab8949fe3ab8c5
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/fast/css/invalidation/rule-change.html
|
| @@ -0,0 +1,29 @@
|
| +<!DOCTYPE html>
|
| +<html>
|
| +<head>
|
| +<script src="../../../resources/testharness.js"></script>
|
| +<script src="../../../resources/testharnessreport.js"></script>
|
| +</head>
|
| +<body>
|
| +<div></div>
|
| +<div id="t1">
|
| + <div id="t2"></div>
|
| + <div></div>
|
| + <div></div>
|
| +</div>
|
| +<script>
|
| + test(() => {
|
| + var s = document.createElement("style");
|
| + s.textContent = "div ~ div > :nth-child(even) { background-color: red }";
|
| + var head = document.querySelector("head");
|
| + head.appendChild(s);
|
| + t2.offsetTop;
|
| + head.removeChild(s);
|
| + t2.offsetTop;
|
| +
|
| + t1.insertBefore(document.createElement("div"), t2);
|
| + assert_equals(internals.updateStyleAndReturnAffectedElementCount(), 1);
|
| + }, "Removed style rules should not cause invalidation");
|
| +</script>
|
| +<body>
|
| +</html>
|
|
|