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

Unified Diff: third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html

Issue 2570263002: DevTools: introduce API for the Common.FormatterWorkerPool. (Closed)
Patch Set: address comments Created 4 years 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/sources/debugger/extract-javascript-identifiers.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html
diff --git a/third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html b/third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html
index 269274f71ead742a40b5ce9a714f340ca8506d01..06cdf380894783491e83b6a1f1a8fa02147e62f1 100644
--- a/third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html
+++ b/third_party/WebKit/LayoutTests/inspector/network/network-json-parser.html
@@ -4,7 +4,6 @@
<script src="../../http/tests/inspector/network-test.js"></script>
<script>
function test() {
- var worker = new Common.Worker("formatter_worker");
function check(jsonText)
{
var resultData = Network.JSONView._extractJSON(jsonText);
@@ -13,12 +12,10 @@ function test() {
return;
}
- worker.onmessage = success;
- worker.postMessage({method: "relaxedJSONParser", params:{content: resultData.data}});
+ Common.formatterWorkerPool.parseJSONRelaxed(resultData.data).then(success);
- function success(event)
+ function success(data)
{
- var data = event.data;
if (data === null) {
failure();
return;
@@ -60,7 +57,6 @@ function test() {
currentTestIndex++;
check(tests[currentTestIndex - 1]);
} else {
- worker.terminate();
InspectorTest.completeTest();
}
}
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/sources/debugger/extract-javascript-identifiers.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698