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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector/stylesheet-source-mapping.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/http/tests/inspector/stylesheet-source-mapping.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/stylesheet-source-mapping.html b/third_party/WebKit/LayoutTests/http/tests/inspector/stylesheet-source-mapping.html
index a990004b4d986fa66d1b98e62398f942cb9c1711..87a7777a8d13c625807bd94def2f959afeb2c7f1 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/stylesheet-source-mapping.html
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/stylesheet-source-mapping.html
@@ -52,9 +52,9 @@ function test()
const documentURL = "http://localhost:8000/inspector/stylesheet-source-mapping.html";
const frame = InspectorTest.resourceTreeModel.mainFrame;
var resource = new WebInspector.Resource(target, null, url, documentURL, frame.id, frame.loaderId, WebInspector.resourceTypes.Stylesheet, mimeType);
- resource.requestContent = function(callback)
+ resource.requestContent = function()
{
- callback(content, false, mimeType);
+ return Promise.resolve(content);
}
return resource;
}
@@ -94,7 +94,7 @@ function test()
InspectorTest.checkUILocation(scssUISourceCode, 4, 11, rawLocationToUILocation(4, 11));
InspectorTest.checkUILocation(scssUISourceCode, 4, 13, rawLocationToUILocation(4, 15));
InspectorTest.checkUILocation(scssUISourceCode, 4, 17, rawLocationToUILocation(4, 20));
- scssUISourceCode.requestContent(didRequestContent);
+ scssUISourceCode.requestContent().then(didRequestContent);
function didRequestContent(content, contentEncoded, mimeType)
{

Powered by Google App Engine
This is Rietveld 408576698