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

Unified Diff: third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html

Issue 1609973002: DevTools: promisify ContentProvider.requestContent and all its clients. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebaseline Created 4 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: third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html
diff --git a/third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html b/third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html
index 1e46130dd320c3d4b4110fa7be4b5bc4d8d341a0..e890b59ebd76d29cfb74e4afc4f2126cea6f91dd 100644
--- a/third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html
+++ b/third_party/WebKit/LayoutTests/inspector-enabled/sources/debugger/script-formatter-console.html
@@ -51,8 +51,7 @@ var test = function()
dumpConsoleMessageURLs();
InspectorTest.addResult("Pre-format row message list:");
InspectorTest.addResult(JSON.stringify(Object.keys(sourceFrame._rowMessageBuckets)));
- InspectorTest.addSniffer(WebInspector.ScriptFormatterEditorAction.prototype, "_updateButton", uiSourceCodeScriptFormatted);
- scriptFormatter._toggleFormatScriptSource();
+ formatVisibleSourceFrame(uiSourceCodeScriptFormatted);
pfeldman 2016/01/20 19:23:51 InspectorTest.showScriptSource
lushnikov 2016/01/20 23:35:58 Done.
}
function uiSourceCodeScriptFormatted()
@@ -66,6 +65,22 @@ var test = function()
}
]);
+ function formatVisibleSourceFrame(callback)
+ {
+ InspectorTest.addSniffer(WebInspector.ScriptFormatterEditorAction.prototype, "_updateButton", onSourceFormatted);
+ scriptFormatter._toggleFormatScriptSource();
+
+ function onSourceFormatted()
+ {
+ var formattedSourceFrame = panel.visibleView;
+ if (formattedSourceFrame.loaded) {
+ callback();
+ return;
+ }
+ InspectorTest.addSniffer(WebInspector.UISourceCodeFrame.prototype, "onTextEditorContentLoaded", callback);
+ }
+ }
+
function dumpConsoleMessageURLs()
{
var messages = WebInspector.ConsolePanel._view()._visibleViewMessages;

Powered by Google App Engine
This is Rietveld 408576698