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

Unified Diff: LayoutTests/inspector/styles/styles-history.html

Issue 148523012: DevTools: [CSS] remove getAllStylesheets method from protocol (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix testcase extension Created 6 years, 11 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: LayoutTests/inspector/styles/styles-history.html
diff --git a/LayoutTests/inspector/styles/styles-history.html b/LayoutTests/inspector/styles/styles-history.html
index 9de8f7fee8a89e3e6a778bdd16f40606acdbbcac..55ffedc56773d19f857ede02e5f4833cf59fcb91 100644
--- a/LayoutTests/inspector/styles/styles-history.html
+++ b/LayoutTests/inspector/styles/styles-history.html
@@ -6,6 +6,7 @@
<script src="../../http/tests/inspector/inspector-test.js"></script>
<script src="../../http/tests/inspector/elements-test.js"></script>
<script src="../../http/tests/inspector/resources-test.js"></script>
+<script src="styles-test.js"></script>
<script>
function test()
@@ -86,21 +87,15 @@ function test()
function styleSheetForResource(callback)
{
- CSSAgent.getAllStyleSheets(didGetAllStyleSheets.bind(this));
+ InspectorTest.waitForStylesheetsOnFrontend(1, didGetAllStyleSheets.bind(this));
- function didGetAllStyleSheets(error, infos)
+ function didGetAllStyleSheets(styleSheets)
{
- if (error) {
- InspectorTest.addResult("Error:" + error);
- callback(null);
- return;
- }
-
- for (var i = 0; i < infos.length; ++i) {
- var info = infos[i];
- if (info.sourceURL.indexOf("styles-history.css") === -1)
+ for (var i = 0; i < styleSheets.length; ++i) {
+ var styleSheet = styleSheets[i];
+ if (styleSheet.sourceURL.indexOf("styles-history.css") === -1)
continue;
- WebInspector.CSSStyleSheet.createForId(info.styleSheetId, callback);
+ WebInspector.CSSStyleSheet.createForId(styleSheet.id, callback);
return;
}
callback(null);
« no previous file with comments | « LayoutTests/inspector/styles/set-property-boundaries.html ('k') | LayoutTests/inspector/styles/styles-new-API.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698