| Index: third_party/WebKit/LayoutTests/inspector/components/viewport-datagrid.html
|
| diff --git a/third_party/WebKit/LayoutTests/inspector/components/viewport-datagrid.html b/third_party/WebKit/LayoutTests/inspector/components/viewport-datagrid.html
|
| index 5154f54f088bd095dfdebc577d13a84a82b6691f..8921c2f28e4f9a7d6961ffd8de1e0c81a001280f 100644
|
| --- a/third_party/WebKit/LayoutTests/inspector/components/viewport-datagrid.html
|
| +++ b/third_party/WebKit/LayoutTests/inspector/components/viewport-datagrid.html
|
| @@ -51,6 +51,16 @@ function test()
|
| InspectorTest.addResult("");
|
| }
|
|
|
| + function revealChildAndDumpClassAndVisibleNodes(index) {
|
| + root.children[index].revealAndSelect();
|
| + dataGrid.updateInstantly();
|
| +
|
| + InspectorTest.addResult(`Class list: ${dataGrid.element.classList}`);
|
| +
|
| + for (var node of dataGrid._visibleNodes)
|
| + InspectorTest.addResult(node.data.id);
|
| + }
|
| +
|
| var columns = [{id: "id", title: "ID column", width: "250px"}];
|
| var dataGrid = new DataGrid.ViewportDataGrid(columns);
|
| var a = new DataGrid.ViewportDataGridNode({id: "a"});
|
| @@ -70,6 +80,7 @@ function test()
|
| containerElement.appendChild(dataGrid.element);
|
| dataGrid.wasShown();
|
| dataGrid.element.style.width = "100%";
|
| + dataGrid.element.style.height = "100%";
|
|
|
| InspectorTest.addResult("Building tree.");
|
|
|
| @@ -164,6 +175,16 @@ function test()
|
| root.appendChild(children[i]);
|
| }
|
| dataGrid.updateInstantly();
|
| +
|
| + dataGrid.setStriped(true);
|
| + InspectorTest.addResult('Scrolling to the top');
|
| + revealChildAndDumpClassAndVisibleNodes(0);
|
| + InspectorTest.addResult('Scrolling 1 node down');
|
| + revealChildAndDumpClassAndVisibleNodes(dataGrid._visibleNodes.length);
|
| + InspectorTest.addResult('Disabling the stripes');
|
| + dataGrid.setStriped(false);
|
| + InspectorTest.addResult(`Class list: ${dataGrid.element.classList}`);
|
| +
|
| InspectorTest.completeTest();
|
| }
|
| </script>
|
|
|