Skip to content

Commit 34d595d

Browse files
committed
rustdoc: add test case for setting-line margin on settings.html
1 parent 9ee4df0 commit 34d595d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/rustdoc-gui/settings.goml

+7
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ assert-false: "#settings"
88
click: "#settings-menu"
99
wait-for: "#settings"
1010
assert-css: ("#settings", {"display": "block"})
11+
12+
// Store the line margin to compare with the settings.html later.
13+
store-css: (setting_line_margin, ".setting-line", "margin")
14+
1115
// Let's close it by clicking on the same button.
1216
click: "#settings-menu"
1317
wait-for-css: ("#settings", {"display": "none"})
@@ -211,6 +215,9 @@ assert-css: (".setting-line", {"position": "relative"})
211215
assert-attribute-false: ("#settings", {"class": "popover"}, CONTAINS)
212216
compare-elements-position: (".sub form", "#settings", ("x"))
213217

218+
// Check that setting-line has the same margin in this mode as in the popover.
219+
assert-css: (".setting-line", {"margin": |setting_line_margin|})
220+
214221
// We now check the display with JS disabled.
215222
assert-false: "noscript section"
216223
javascript: false

0 commit comments

Comments
 (0)