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

Unified Diff: headless/public/util/dom_tree_extractor_browsertest.cc

Issue 2455613002: Fix index used to join results of DOM.getDocument and CSS.getLayoutTreeAndStyles (Closed)
Patch Set: Fix skew between property names and values when emepty ones are skipped. Created 4 years, 2 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: headless/public/util/dom_tree_extractor_browsertest.cc
diff --git a/headless/public/util/dom_tree_extractor_browsertest.cc b/headless/public/util/dom_tree_extractor_browsertest.cc
index fac4fe7b5d1571d002a3488077ee6634c6fcef73..5967ff659e9c69d5f2948b4dea9c9c8c07560fe2 100644
--- a/headless/public/util/dom_tree_extractor_browsertest.cc
+++ b/headless/public/util/dom_tree_extractor_browsertest.cc
@@ -102,8 +102,7 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
// Merge LayoutTreeNode data into the dictionaries.
for (const css::LayoutTreeNode* layout_node : dom_tree.layout_tree_nodes_) {
- auto it =
- dom_tree.node_id_to_index_.find(layout_node->GetBackendNodeId());
+ auto it = dom_tree.node_id_to_index_.find(layout_node->GetNodeId());
ASSERT_TRUE(it != dom_tree.node_id_to_index_.end());
base::DictionaryValue* node_dict = dom_nodes[it->second].get();
@@ -142,6 +141,12 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
const std::vector<std::string> expected_dom_nodes = {
"{\n"
" 'baseURL': 'http://127.0.0.1/dom_tree_test.html',\n"
+ " 'boundingBox': {\n"
+ " 'height': 600.0,\n"
+ " 'width': 800.0,\n"
+ " 'x': 0.0,\n"
+ " 'y': 0.0\n"
+ " },\n"
" 'childIndices': [ 1 ],\n"
" 'documentURL': 'http://127.0.0.1/dom_tree_test.html',\n"
" 'localName': '',\n"
@@ -154,68 +159,54 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
"{\n"
" 'attributes': [ ],\n"
+ " 'boundingBox': {\n"
+ " 'height': 600.0,\n"
+ " 'width': 800.0,\n"
+ " 'x': 0.0,\n"
+ " 'y': 0.0\n"
+ " },\n"
" 'childIndices': [ 2, 5 ],\n"
" 'frameId': '?',\n"
" 'localName': 'html',\n"
" 'nodeId': 2,\n"
" 'nodeName': 'HTML',\n"
" 'nodeType': 1,\n"
- " 'nodeValue': ''\n"
+ " 'nodeValue': '',\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
- " 'boundingBox': {\n"
- " 'height': 600.0,\n"
- " 'width': 800.0,\n"
- " 'x': 0.0,\n"
- " 'y': 0.0\n"
- " },\n"
" 'childIndices': [ 3 ],\n"
" 'localName': 'head',\n"
" 'nodeId': 3,\n"
" 'nodeName': 'HEAD',\n"
" 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 0\n"
+ " 'nodeValue': ''\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
- " 'boundingBox': {\n"
- " 'height': 600.0,\n"
- " 'width': 800.0,\n"
- " 'x': 0.0,\n"
- " 'y': 0.0\n"
- " },\n"
" 'childIndices': [ 4 ],\n"
" 'localName': 'title',\n"
" 'nodeId': 4,\n"
" 'nodeName': 'TITLE',\n"
" 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 1\n"
+ " 'nodeValue': ''\n"
"}\n",
"{\n"
- " 'boundingBox': {\n"
- " 'height': 584.0,\n"
- " 'width': 784.0,\n"
- " 'x': 8.0,\n"
- " 'y': 8.0\n"
- " },\n"
" 'localName': '',\n"
" 'nodeId': 5,\n"
" 'nodeName': '#text',\n"
" 'nodeType': 3,\n"
- " 'nodeValue': 'Hello world!',\n"
- " 'styleIndex': 2\n"
+ " 'nodeValue': 'Hello world!'\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
" 'boundingBox': {\n"
- " 'height': 367.0,\n"
+ " 'height': 584.0,\n"
" 'width': 784.0,\n"
" 'x': 8.0,\n"
" 'y': 8.0\n"
@@ -232,7 +223,7 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
"{\n"
" 'attributes': [ 'id', 'id1' ],\n"
" 'boundingBox': {\n"
- " 'height': 37.0,\n"
+ " 'height': 367.0,\n"
" 'width': 784.0,\n"
" 'x': 8.0,\n"
" 'y': 8.0\n"
@@ -243,18 +234,33 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': 'DIV',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 3\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ 'style', 'color: red' ],\n"
" 'boundingBox': {\n"
+ " 'height': 37.0,\n"
+ " 'width': 784.0,\n"
+ " 'x': 8.0,\n"
+ " 'y': 8.0\n"
+ " },\n"
+ " 'childIndices': [ 8 ],\n"
+ " 'localName': 'h1',\n"
+ " 'nodeId': 8,\n"
+ " 'nodeName': 'H1',\n"
+ " 'nodeType': 1,\n"
+ " 'nodeValue': '',\n"
+ " 'styleIndex': 2\n"
+ "}\n",
+
+ "{\n"
+ " 'boundingBox': {\n"
" 'height': 36.0,\n"
" 'width': 143.0,\n"
" 'x': 8.0,\n"
" 'y': 8.0\n"
" },\n"
- " 'childIndices': [ 8 ],\n"
" 'inlineTextNodes': [ {\n"
" 'boundingBox': {\n"
" 'height': 36.0,\n"
@@ -266,37 +272,22 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'startCharacterIndex': 0\n"
" } ],\n"
" 'layoutText': 'Some text.',\n"
- " 'localName': 'h1',\n"
- " 'nodeId': 8,\n"
- " 'nodeName': 'H1',\n"
- " 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 3\n"
- "}\n",
-
- "{\n"
- " 'boundingBox': {\n"
- " 'height': 200.0,\n"
- " 'width': 400.0,\n"
- " 'x': 10.0,\n"
- " 'y': 68.0\n"
- " },\n"
" 'localName': '',\n"
" 'nodeId': 9,\n"
" 'nodeName': '#text',\n"
" 'nodeType': 3,\n"
" 'nodeValue': 'Some text.',\n"
- " 'styleIndex': 1\n"
+ " 'styleIndex': 2\n"
"}\n",
"{\n"
" 'attributes': [ 'src', '/iframe.html', 'width', '400', 'height', "
"'200' ],\n"
" 'boundingBox': {\n"
- " 'height': 171.0,\n"
- " 'width': 384.0,\n"
- " 'x': 18.0,\n"
- " 'y': 76.0\n"
+ " 'height': 205.0,\n"
+ " 'width': 404.0,\n"
+ " 'x': 8.0,\n"
+ " 'y': 66.0\n"
" },\n"
" 'childIndices': [ ],\n"
" 'contentDocumentIndex': 10,\n"
@@ -306,17 +297,11 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': 'IFRAME',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 2\n"
+ " 'styleIndex': 4\n"
"}\n",
"{\n"
" 'baseURL': 'http://127.0.0.1/iframe.html',\n"
- " 'boundingBox': {\n"
- " 'height': 37.0,\n"
- " 'width': 384.0,\n"
- " 'x': 18.0,\n"
- " 'y': 76.0\n"
- " },\n"
" 'childIndices': [ 11 ],\n"
" 'documentURL': 'http://127.0.0.1/iframe.html',\n"
" 'localName': '',\n"
@@ -324,66 +309,46 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': '#document',\n"
" 'nodeType': 9,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 4,\n"
" 'xmlVersion': ''\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
" 'boundingBox': {\n"
- " 'height': 36.0,\n"
- " 'width': 308.0,\n"
- " 'x': 8.0,\n"
- " 'y': 8.0\n"
+ " 'height': 200.0,\n"
+ " 'width': 400.0,\n"
+ " 'x': 10.0,\n"
+ " 'y': 68.0\n"
" },\n"
" 'childIndices': [ 12, 13 ],\n"
" 'frameId': '?',\n"
- " 'inlineTextNodes': [ {\n"
- " 'boundingBox': {\n"
- " 'height': 36.0,\n"
- " 'width': 307.734375,\n"
- " 'x': 8.0,\n"
- " 'y': 8.0\n"
- " },\n"
- " 'numCharacters': 22,\n"
- " 'startCharacterIndex': 0\n"
- " } ],\n"
- " 'layoutText': 'Hello from the iframe!',\n"
" 'localName': 'html',\n"
" 'nodeId': 12,\n"
" 'nodeName': 'HTML',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 4\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
- " 'boundingBox': {\n"
- " 'height': 205.0,\n"
- " 'width': 404.0,\n"
- " 'x': 8.0,\n"
- " 'y': 66.0\n"
- " },\n"
" 'childIndices': [ ],\n"
" 'localName': 'head',\n"
" 'nodeId': 13,\n"
" 'nodeName': 'HEAD',\n"
" 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 5\n"
+ " 'nodeValue': ''\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
" 'boundingBox': {\n"
- " 'height': 0.0,\n"
- " 'width': 0.0,\n"
- " 'x': 0.0,\n"
- " 'y': 0.0\n"
+ " 'height': 171.0,\n"
+ " 'width': 384.0,\n"
+ " 'x': 18.0,\n"
+ " 'y': 76.0\n"
" },\n"
" 'childIndices': [ 14 ],\n"
- " 'layoutText': '\\n',\n"
" 'localName': 'body',\n"
" 'nodeId': 14,\n"
" 'nodeName': 'BODY',\n"
@@ -395,10 +360,10 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
"{\n"
" 'attributes': [ ],\n"
" 'boundingBox': {\n"
- " 'height': 105.0,\n"
- " 'width': 784.0,\n"
- " 'x': 8.0,\n"
- " 'y': 270.0\n"
+ " 'height': 37.0,\n"
+ " 'width': 384.0,\n"
+ " 'x': 18.0,\n"
+ " 'y': 76.0\n"
" },\n"
" 'childIndices': [ 15 ],\n"
" 'localName': 'h1',\n"
@@ -406,22 +371,33 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': 'H1',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 1\n"
+ " 'styleIndex': 3\n"
"}\n",
"{\n"
" 'boundingBox': {\n"
- " 'height': 105.0,\n"
- " 'width': 784.0,\n"
+ " 'height': 36.0,\n"
+ " 'width': 308.0,\n"
" 'x': 8.0,\n"
- " 'y': 270.0\n"
+ " 'y': 8.0\n"
" },\n"
+ " 'inlineTextNodes': [ {\n"
+ " 'boundingBox': {\n"
+ " 'height': 36.0,\n"
+ " 'width': 307.734375,\n"
+ " 'x': 8.0,\n"
+ " 'y': 8.0\n"
+ " },\n"
+ " 'numCharacters': 22,\n"
+ " 'startCharacterIndex': 0\n"
+ " } ],\n"
+ " 'layoutText': 'Hello from the iframe!',\n"
" 'localName': '',\n"
" 'nodeId': 16,\n"
" 'nodeName': '#text',\n"
" 'nodeType': 3,\n"
" 'nodeValue': 'Hello from the iframe!',\n"
- " 'styleIndex': 1\n"
+ " 'styleIndex': 3\n"
"}\n",
"{\n"
@@ -438,14 +414,14 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': 'DIV',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 1\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ 'id', 'id3' ],\n"
" 'boundingBox': {\n"
- " 'height': 18.0,\n"
- " 'width': 53.0,\n"
+ " 'height': 105.0,\n"
+ " 'width': 784.0,\n"
" 'x': 8.0,\n"
" 'y': 270.0\n"
" },\n"
@@ -455,79 +431,93 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'nodeName': 'DIV',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 6\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ 'id', 'id4' ],\n"
" 'boundingBox': {\n"
- " 'height': 18.0,\n"
- " 'width': 53.0,\n"
+ " 'height': 105.0,\n"
+ " 'width': 784.0,\n"
" 'x': 8.0,\n"
" 'y': 270.0\n"
" },\n"
" 'childIndices': [ 19, 21, 23, 24 ],\n"
- " 'inlineTextNodes': [ {\n"
- " 'boundingBox': {\n"
- " 'height': 17.0,\n"
- " 'width': 52.421875,\n"
- " 'x': 8.0,\n"
- " 'y': 270.4375\n"
- " },\n"
- " 'numCharacters': 7,\n"
- " 'startCharacterIndex': 0\n"
- " } ],\n"
- " 'layoutText': 'Google!',\n"
" 'localName': 'div',\n"
" 'nodeId': 19,\n"
" 'nodeName': 'DIV',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 6\n"
+ " 'styleIndex': 0\n"
"}\n",
"{\n"
" 'attributes': [ 'href', 'https://www.google.com' ],\n"
" 'boundingBox': {\n"
- " 'height': 0.0,\n"
- " 'width': 0.0,\n"
- " 'x': 0.0,\n"
- " 'y': 0.0\n"
+ " 'height': 18.0,\n"
+ " 'width': 53.0,\n"
+ " 'x': 8.0,\n"
+ " 'y': 270.0\n"
" },\n"
" 'childIndices': [ 20 ],\n"
- " 'layoutText': '\\n ',\n"
" 'localName': 'a',\n"
" 'nodeId': 20,\n"
" 'nodeName': 'A',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 1\n"
+ " 'styleIndex': 5\n"
"}\n",
"{\n"
" 'boundingBox': {\n"
- " 'height': 19.0,\n"
- " 'width': 784.0,\n"
+ " 'height': 18.0,\n"
+ " 'width': 53.0,\n"
" 'x': 8.0,\n"
- " 'y': 304.0\n"
+ " 'y': 270.0\n"
" },\n"
+ " 'inlineTextNodes': [ {\n"
+ " 'boundingBox': {\n"
+ " 'height': 17.0,\n"
+ " 'width': 52.421875,\n"
+ " 'x': 8.0,\n"
+ " 'y': 270.4375\n"
+ " },\n"
+ " 'numCharacters': 7,\n"
+ " 'startCharacterIndex': 0\n"
+ " } ],\n"
+ " 'layoutText': 'Google!',\n"
" 'localName': '',\n"
" 'nodeId': 21,\n"
" 'nodeName': '#text',\n"
" 'nodeType': 3,\n"
" 'nodeValue': 'Google!',\n"
- " 'styleIndex': 7\n"
+ " 'styleIndex': 5\n"
"}\n",
"{\n"
" 'attributes': [ ],\n"
" 'boundingBox': {\n"
+ " 'height': 19.0,\n"
+ " 'width': 784.0,\n"
+ " 'x': 8.0,\n"
+ " 'y': 304.0\n"
+ " },\n"
+ " 'childIndices': [ 22 ],\n"
+ " 'localName': 'p',\n"
+ " 'nodeId': 22,\n"
+ " 'nodeName': 'P',\n"
+ " 'nodeType': 1,\n"
+ " 'nodeValue': '',\n"
+ " 'styleIndex': 6\n"
+ "}\n",
+
+ "{\n"
+ " 'boundingBox': {\n"
" 'height': 18.0,\n"
" 'width': 85.0,\n"
" 'x': 8.0,\n"
" 'y': 304.0\n"
" },\n"
- " 'childIndices': [ 22 ],\n"
" 'inlineTextNodes': [ {\n"
" 'boundingBox': {\n"
" 'height': 17.0,\n"
@@ -539,21 +529,23 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'startCharacterIndex': 0\n"
" } ],\n"
" 'layoutText': 'A paragraph!',\n"
- " 'localName': 'p',\n"
- " 'nodeId': 22,\n"
- " 'nodeName': 'P',\n"
- " 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 7\n"
+ " 'localName': '',\n"
+ " 'nodeId': 23,\n"
+ " 'nodeName': '#text',\n"
+ " 'nodeType': 3,\n"
+ " 'nodeValue': 'A paragraph!',\n"
+ " 'styleIndex': 6\n"
"}\n",
"{\n"
+ " 'attributes': [ ],\n"
" 'boundingBox': {\n"
" 'height': 0.0,\n"
" 'width': 0.0,\n"
" 'x': 0.0,\n"
" 'y': 0.0\n"
" },\n"
+ " 'childIndices': [ ],\n"
" 'inlineTextNodes': [ {\n"
" 'boundingBox': {\n"
" 'height': 17.0,\n"
@@ -565,40 +557,38 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'startCharacterIndex': 0\n"
" } ],\n"
" 'layoutText': '\\n',\n"
- " 'localName': '',\n"
- " 'nodeId': 23,\n"
- " 'nodeName': '#text',\n"
- " 'nodeType': 3,\n"
- " 'nodeValue': 'A paragraph!',\n"
- " 'styleIndex': 5\n"
+ " 'localName': 'br',\n"
+ " 'nodeId': 24,\n"
+ " 'nodeName': 'BR',\n"
+ " 'nodeType': 1,\n"
+ " 'nodeValue': '',\n"
+ " 'styleIndex': 4\n"
"}\n",
"{\n"
- " 'attributes': [ ],\n"
+ " 'attributes': [ 'style', 'color: green' ],\n"
" 'boundingBox': {\n"
" 'height': 19.0,\n"
" 'width': 784.0,\n"
" 'x': 8.0,\n"
" 'y': 356.0\n"
" },\n"
- " 'childIndices': [ ],\n"
- " 'localName': 'br',\n"
- " 'nodeId': 24,\n"
- " 'nodeName': 'BR',\n"
+ " 'childIndices': [ 25, 26, 28 ],\n"
+ " 'localName': 'div',\n"
+ " 'nodeId': 25,\n"
+ " 'nodeName': 'DIV',\n"
" 'nodeType': 1,\n"
" 'nodeValue': '',\n"
- " 'styleIndex': 8\n"
+ " 'styleIndex': 7\n"
"}\n",
"{\n"
- " 'attributes': [ 'style', 'color: green' ],\n"
" 'boundingBox': {\n"
" 'height': 18.0,\n"
" 'width': 41.0,\n"
" 'x': 8.0,\n"
" 'y': 356.0\n"
" },\n"
- " 'childIndices': [ 25, 26, 28 ],\n"
" 'inlineTextNodes': [ {\n"
" 'boundingBox': {\n"
" 'height': 17.0,\n"
@@ -610,38 +600,38 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'startCharacterIndex': 0\n"
" } ],\n"
" 'layoutText': 'Some ',\n"
- " 'localName': 'div',\n"
- " 'nodeId': 25,\n"
- " 'nodeName': 'DIV',\n"
- " 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 8\n"
+ " 'localName': '',\n"
+ " 'nodeId': 26,\n"
+ " 'nodeName': '#text',\n"
+ " 'nodeType': 3,\n"
+ " 'nodeValue': 'Some ',\n"
+ " 'styleIndex': 7\n"
"}\n",
"{\n"
+ " 'attributes': [ ],\n"
" 'boundingBox': {\n"
" 'height': 18.0,\n"
" 'width': 37.0,\n"
" 'x': 48.0,\n"
" 'y': 356.0\n"
" },\n"
- " 'localName': '',\n"
- " 'nodeId': 26,\n"
- " 'nodeName': '#text',\n"
- " 'nodeType': 3,\n"
- " 'nodeValue': 'Some ',\n"
- " 'styleIndex': 9\n"
+ " 'childIndices': [ 27 ],\n"
+ " 'localName': 'em',\n"
+ " 'nodeId': 27,\n"
+ " 'nodeName': 'EM',\n"
+ " 'nodeType': 1,\n"
+ " 'nodeValue': '',\n"
+ " 'styleIndex': 8\n"
"}\n",
"{\n"
- " 'attributes': [ ],\n"
" 'boundingBox': {\n"
" 'height': 18.0,\n"
" 'width': 37.0,\n"
" 'x': 48.0,\n"
" 'y': 356.0\n"
" },\n"
- " 'childIndices': [ 27 ],\n"
" 'inlineTextNodes': [ {\n"
" 'boundingBox': {\n"
" 'height': 17.0,\n"
@@ -653,12 +643,12 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" 'startCharacterIndex': 0\n"
" } ],\n"
" 'layoutText': 'green',\n"
- " 'localName': 'em',\n"
- " 'nodeId': 27,\n"
- " 'nodeName': 'EM',\n"
- " 'nodeType': 1,\n"
- " 'nodeValue': '',\n"
- " 'styleIndex': 9\n"
+ " 'localName': '',\n"
+ " 'nodeId': 28,\n"
+ " 'nodeName': '#text',\n"
+ " 'nodeType': 3,\n"
+ " 'nodeValue': 'green',\n"
+ " 'styleIndex': 8\n"
"}\n",
"{\n"
@@ -680,19 +670,11 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
" } ],\n"
" 'layoutText': ' text...',\n"
" 'localName': '',\n"
- " 'nodeId': 28,\n"
- " 'nodeName': '#text',\n"
- " 'nodeType': 3,\n"
- " 'nodeValue': 'green',\n"
- " 'styleIndex': 8\n"
- "}\n",
-
- "{\n"
- " 'localName': '',\n"
" 'nodeId': 29,\n"
" 'nodeName': '#text',\n"
" 'nodeType': 3,\n"
- " 'nodeValue': ' text...'\n"
+ " 'nodeValue': ' text...',\n"
+ " 'styleIndex': 7\n"
"}\n"};
EXPECT_EQ(expected_dom_nodes.size(), dom_nodes.size());
@@ -710,16 +692,6 @@ class DomTreeExtractorBrowserTest : public HeadlessAsyncDevTooledBrowserTest,
const std::vector<std::string> expected_styles = {
"{\n"
- " 'color': '',\n"
- " 'display': '',\n"
- " 'font-style': '',\n"
- " 'margin-bottom': '',\n"
- " 'margin-left': '',\n"
- " 'margin-right': '',\n"
- " 'margin-top': ''\n"
- "}\n",
-
- "{\n"
" 'color': 'rgb(0, 0, 0)',\n"
" 'display': 'block',\n"
" 'font-style': 'normal',\n"

Powered by Google App Engine
This is Rietveld 408576698