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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector-protocol/runtime/runtime-getProperties-preview.js

Issue 2954093003: [DevTools] Migrate inspector-protocol/runtime tests to new harness (Closed)
Patch Set: fail: Created 3 years, 5 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 unified diff | Download patch
OLDNEW
(Empty)
1 (async function(testRunner) {
2 let {page, session, dp} = await testRunner.startBlank(``);
3
4 function printResult(response) {
5 for (var property of response.result.result) {
6 if (!property.value || property.name === '__proto__')
7 continue;
8 if (property.value.preview)
9 testRunner.log(property.name + ' : ' + JSON.stringify(property.value.pre view, null, 4));
10 else
11 testRunner.log(property.name + ' : ' + property.value.description);
12 }
13 }
14
15 var response = await dp.Runtime.evaluate({expression: `({p1: {a:1}, p2: {b:'fo o', bb:'bar'}})`});
16 printResult(await dp.Runtime.getProperties({objectId: response.result.result.o bjectId, ownProperties: true }));
17 printResult(await dp.Runtime.getProperties({objectId: response.result.result.o bjectId, ownProperties: true, generatePreview: true }));
18 testRunner.completeTest();
19 })
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698