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

Unified Diff: LayoutTests/inspector/elements/styles-4/styles-new-API.html

Issue 1196193016: DevTools: [CSS] promisify CSS domain (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: address comments 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/inspector/elements/styles-4/styles-new-API.html
diff --git a/LayoutTests/inspector/elements/styles-4/styles-new-API.html b/LayoutTests/inspector/elements/styles-4/styles-new-API.html
index 5c2278d16cf0175ca76c0513fed8490f949b6b31..2e333620a7fb9263030e4e6208551ac7d3f395d1 100644
--- a/LayoutTests/inspector/elements/styles-4/styles-new-API.html
+++ b/LayoutTests/inspector/elements/styles-4/styles-new-API.html
@@ -79,15 +79,17 @@ function test()
resultStyles.matchedCSSRules = matchedCSSRules;
resultStyles.pseudoElements = pseudoElements;
resultStyles.inherited = inherited;
- callback(resultStyles);
}
function nodeCallback(node)
{
bodyId = node.id;
- InspectorTest.CSSAgent.getComputedStyleForNode(node.id, computedCallback);
- InspectorTest.CSSAgent.getInlineStylesForNode(node.id, inlineCallback);
- InspectorTest.CSSAgent.getMatchedStylesForNode(node.id, false, false, matchedCallback);
+ var promises = [
+ InspectorTest.CSSAgent.getComputedStyleForNode(node.id, computedCallback),
+ InspectorTest.CSSAgent.getInlineStylesForNode(node.id, inlineCallback),
+ InspectorTest.CSSAgent.getMatchedStylesForNode(node.id, false, false, matchedCallback)
+ ];
+ Promise.all(promises).then(callback.bind(null, resultStyles));
}
InspectorTest.selectNodeWithId("mainBody", nodeCallback);
},

Powered by Google App Engine
This is Rietveld 408576698