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

Unified Diff: third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html

Issue 2139043002: DevTools: show alternate title onexpand of object in console (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments Created 4 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html
diff --git a/third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html b/third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html
index e424e064ed4756c0d3ab01a16f24bd358ddace42..cfec9bfb491503b51e6a89e0844efd8784e98db8 100644
--- a/third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html
+++ b/third_party/WebKit/LayoutTests/inspector/console/console-format-broken-unicode.html
@@ -29,18 +29,30 @@ function test()
function step3()
{
- InspectorTest.evaluateInPage("obj.foo", step4);
+ InspectorTest.expandConsoleMessages(step4, nestedObjectFilter);
}
- function step4(result)
+ function step4()
+ {
+ InspectorTest.evaluateInPage("obj.foo", step5);
+ }
+
+ function step5(result)
{
var text = result.description;
InspectorTest.assertEquals(15, text.length, "text length");
- InspectorTest.assertEquals(7, countTextNodes(text), "nodes count");
+ InspectorTest.assertEquals(6, countTextNodes(text), "nodes count");
InspectorTest.addResult("PASS: Found all nodes with the broken text");
InspectorTest.completeTest();
}
+ function nestedObjectFilter(treeElement)
lushnikov 2016/07/30 00:29:49 can you please explain this filter?
luoe 2016/07/30 01:46:37 In the broken unicode test, it evaluates [{ ..inte
+ {
+ var name = treeElement.nameElement && treeElement.nameElement.textContent;
+ var titleName = treeElement.treeOutline.titleElement && treeElement.treeOutline.titleElement.textContent;
+ return name === "0" || titleName === "Array[1]";
+ }
+
function countTextNodes(textContent)
{
InspectorTest.disableConsoleViewport();

Powered by Google App Engine
This is Rietveld 408576698