Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Unified Diff: third_party/WebKit/LayoutTests/inspector/elements/styles-4/styles-update-links-1.html

Issue 2182393003: DevTools: split inspector/elements/styles-4/styles-update-links.html into 4 tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/inspector/elements/styles-4/styles-update-links-1.html
diff --git a/third_party/WebKit/LayoutTests/inspector/elements/styles-4/styles-update-links-1.html b/third_party/WebKit/LayoutTests/inspector/elements/styles-4/styles-update-links-1.html
new file mode 100644
index 0000000000000000000000000000000000000000..dace7fe39ab9a53b9330909b7474f9c5975526a2
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/inspector/elements/styles-4/styles-update-links-1.html
@@ -0,0 +1,67 @@
+<html>
+<head>
+<script src="../../../http/tests/inspector/inspector-test.js"></script>
+<script src="../../../http/tests/inspector/elements-test.js"></script>
+<script src="./styles-update-links.js"></script>
+<style>
+#pseudo::after {
+ pseudo-property: "12";
+ color: red;
+}
+
+#pseudo::after {
+ border: 1px solid black;
+}
+
+#pseudo::before {
+ color: blue;
+}
+</style>
+<script>
+
+function test()
+{
+ InspectorTest.runTestSuite([
+ function selectInitialNode(next)
+ {
+ InspectorTest.selectNodeAndWaitForStyles("container", next);
+ },
+
+ function testInsertProperty(next)
+ {
+ InspectorTest.dumpSelectedElementStyles(true, false, true);
+ var treeItem = InspectorTest.getMatchedStylePropertyTreeItem("color");
+ var treeElement = treeItem.section().addNewBlankProperty(1);
+ InspectorTest.waitForStyleApplied(onPropertyInserted);
+ treeElement.applyStyleText("PROPERTY: INSERTED;", true);
+
+ function onPropertyInserted()
+ {
+ InspectorTest.addResult("\n\n#### AFTER PROPERTY INSERTION ####\n\n");
+ InspectorTest.dumpSelectedElementStyles(true, false, true);
+ var rules = InspectorTest.getMatchedRules();
+ InspectorTest.validateRuleRanges("container", rules, next);
+ }
+ }
+ ]);
+}
+</script>
+<link rel="stylesheet" href="../styles/resources/styles-update-links-2.css"></link>
+<link rel="stylesheet" href="../styles/resources/styles-update-links.css"></link>
+</head>
+
+<body onload="runTest()">
+<p>
+Tests that links are updated properly when inserting a new property.
+</p>
+
+<div id="container" class="left-intact should-change">
+Red text here.
+</div>
+
+<div id="other"></div>
+
+<section id="pseudo"></div>
+
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698