summaryrefslogtreecommitdiffstats
path: root/devtools/client/inspector/rules/test/browser_rules_variables_02.js
diff options
context:
space:
mode:
Diffstat (limited to 'devtools/client/inspector/rules/test/browser_rules_variables_02.js')
-rw-r--r--devtools/client/inspector/rules/test/browser_rules_variables_02.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/devtools/client/inspector/rules/test/browser_rules_variables_02.js b/devtools/client/inspector/rules/test/browser_rules_variables_02.js
index 4100859fb9..ee37a7b07a 100644
--- a/devtools/client/inspector/rules/test/browser_rules_variables_02.js
+++ b/devtools/client/inspector/rules/test/browser_rules_variables_02.js
@@ -119,9 +119,14 @@ async function testBorderShorthandAndInheritance(inspector, view) {
// var(x) is the next sibling of the parent of M
const setVarXParent = setVarMParent.parentNode.nextElementSibling;
- // var(r) is the next sibling of var(x), and var(g) is the next sibling of var(r), etc.
- const setVarRParent = setVarXParent.nextElementSibling;
+ // var(x) next sibling is the element that wraps the color
+ const colorParent =
+ setVarXParent.nextElementSibling.querySelector(".ruleview-color");
+ // var(r) is the first childElement of the ruleview-color element
+ const setVarRParent = colorParent.firstElementChild;
+ // var(g) is the next sibling of var(r),
const setVarGParent = setVarRParent.nextElementSibling;
+ // and var(b) is the next sibling of var(g),
const setVarBParent = setVarGParent.nextElementSibling;
const setVarM = getVarFromParent(setVarMParent);