3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/elements-test.js"></script>
8 function injectStyleSheet()
10 var styleSheet = "#container { margin: 8px }";
11 if (window.testRunner)
12 window.testRunner.injectStyleSheet(styleSheet, true);
17 InspectorTest.evaluateInPage("injectStyleSheet()", step1);
20 InspectorTest.selectNodeAndWaitForStyles("container", step2);
25 InspectorTest.addResult("Before disable");
26 InspectorTest.dumpSelectedElementStyles(true, false, true);
27 InspectorTest.toggleStyleProperty("margin", false);
28 InspectorTest.waitForStyles("container", step3);
33 InspectorTest.addResult("After disable");
34 InspectorTest.dumpSelectedElementStyles(true, false, true);
35 InspectorTest.toggleStyleProperty("margin", true);
36 InspectorTest.waitForStyles("container", step4);
41 InspectorTest.addResult("After enable");
42 InspectorTest.dumpSelectedElementStyles(true, false, true);
43 InspectorTest.completeTest();
49 <body onload="runTest()" id="body-id">
51 Tests that disabling shorthand removes the "overriden" mark from the UA shorthand it overrides.
54 <div id="container" style="margin: 10px"></div>