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

Side by Side Diff: LayoutTests/inspector/elements/styles/disable-property-workingcopy-update.html

Issue 1158883003: DevTools: shard inspector/elements tests for faster execution. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 <html>
2 <head>
3 <link rel="stylesheet" href="resources/disable-property-workingcopy-update.css">
4 <script src="../../../http/tests/inspector/inspector-test.js"></script>
5 <script src="../../../http/tests/inspector/debugger-test.js"></script>
6 <script src="../../../http/tests/inspector/elements-test.js"></script>
7 <script>
8
9 function test()
10 {
11 var cssSourceFrame;
12 WebInspector.StylesSourceMapping.MinorChangeUpdateTimeoutMs = 10;
13
14 InspectorTest.runTestSuite([
15 function selectContainer(next)
16 {
17 InspectorTest.selectNodeAndWaitForStyles("inspected", next);
18 },
19
20 function showEditor(next)
21 {
22 var headers = InspectorTest.cssModel.styleSheetHeaders();
23 for (var i = 0; i < headers.length; ++i) {
24 if (headers[i].sourceURL.endsWith(".css")) {
25 var cssLocation = new WebInspector.CSSLocation(InspectorTest .cssModel, headers[i].id, headers[i].sourceURL, 0);
26 InspectorTest.showUISourceCode(WebInspector.cssWorkspaceBind ing.rawLocationToUILocation(cssLocation).uiSourceCode, callback);
27 break;
28 }
29 }
30
31 function callback(sourceFrame)
32 {
33 cssSourceFrame = sourceFrame;
34 InspectorTest.dumpSourceFrameContents(cssSourceFrame);
35 next();
36 }
37 },
38
39 function togglePropertyOff(next)
40 {
41 toggleProperty(false, next);
42 },
43
44 function dumpDisabledText(next)
45 {
46 InspectorTest.dumpSourceFrameContents(cssSourceFrame);
47 InspectorTest.dumpSelectedElementStyles(true);
48 next();
49 },
50
51 function togglePropertyOn(next)
52 {
53 toggleProperty(true, next);
54 },
55
56 function dumpEnabledText(next)
57 {
58 InspectorTest.dumpSourceFrameContents(cssSourceFrame);
59 InspectorTest.dumpSelectedElementStyles(true);
60 next();
61 }
62 ]);
63
64 function toggleProperty(value, next)
65 {
66 InspectorTest.addSniffer(WebInspector.UISourceCode.prototype, "addRevisi on", callback);
67 InspectorTest.waitForStyles("inspected", callback);
68 InspectorTest.toggleMatchedStyleProperty("font-weight", value);
69
70 var barrierCounter = 2;
71 function callback()
72 {
73 if (!--barrierCounter)
74 next();
75 }
76 }
77 }
78 </script>
79 </head>
80
81 <body onload="runTest()">
82 <p>
83 Tests that style property disablement is propagated into the stylesheet UISource Code working copy.
84 </p>
85
86 <div id="inspected">
87 </div>
88
89 </body>
90 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698