Bug 1479508 Part 4: Remove a test that only exists to check grids in display:none subtrees -- something no longer targeted by the UI.
This test seems to have no reason to exist anymore. getElementsWithGrid used
to retrieve ALL elements styled with grid, even if they weren't visible.
With the other changes in this patch, we no longer return such grids, and the
case that this test aims to check is no longer something that can occur.
MozReview-Commit-ID: 68AiqYe7uww
--- a/devtools/client/inspector/grids/test/browser.ini
+++ b/devtools/client/inspector/grids/test/browser.ini
@@ -33,12 +33,11 @@ skip-if = (verify && (os == 'win' || os
skip-if = (verify && (os == 'win'))
[browser_grids_grid-outline-highlight-cell.js]
skip-if = (verify && (os == 'win'))
[browser_grids_grid-outline-selected-grid.js]
[browser_grids_grid-outline-updates-on-grid-change.js]
[browser_grids_grid-outline-writing-mode.js]
skip-if = (verify && (os == 'win'))
[browser_grids_highlighter-setting-rules-grid-toggle.js]
-[browser_grids_no_fragments.js]
[browser_grids_number-of-css-grids-telemetry.js]
[browser_grids_persist-color-palette.js]
[browser_grids_restored-after-reload.js]
deleted file mode 100644
--- a/devtools/client/inspector/grids/test/browser_grids_no_fragments.js
+++ /dev/null
@@ -1,49 +0,0 @@
-/* Any copyright is dedicated to the Public Domain.
- http://creativecommons.org/publicdomain/zero/1.0/ */
-
-"use strict";
-
-// Tests that when grids exist but have no fragments, clicking on the checkbox doesn't
-// fail (see bug 1441462).
-
-const TEST_URI = `
- <style type='text/css'>
- #wrapper { display: none; }
- .grid { display: grid; grid-template-columns: 1fr 1fr; }
- </style>
- <div id="wrapper">
- <div class="grid">
- <div>cell1</div>
- <div>cell2</div>
- </div>
- <div class="grid">
- <div>cell1</div>
- <div>cell2</div>
- </div>
- </div>
-`;
-
-add_task(async function() {
- await addTab("data:text/html;charset=utf-8," + encodeURIComponent(TEST_URI));
-
- const { inspector, gridInspector } = await openLayoutView();
- const { document: doc } = gridInspector;
- const { store } = inspector;
-
- const gridList = doc.querySelector("#grid-list");
- is(gridList.children.length, 2, "There are 2 grids in the list");
-
- info("Try to click the first grid's checkbox");
- const checkbox1 = gridList.children[0].querySelector("input");
- const onCheckbox1Change = waitUntilState(store, state =>
- state.grids[0] && state.grids[0].highlighted);
- checkbox1.click();
- await onCheckbox1Change;
-
- info("Try to click the second grid's checkbox");
- const checkbox2 = gridList.children[1].querySelector("input");
- const onCheckbox2Change = waitUntilState(store, state =>
- state.grids[1] && state.grids[1].highlighted);
- checkbox2.click();
- await onCheckbox2Change;
-});