]> git.lizzy.rs Git - rust.git/blob - src/test/rustdoc-gui/help-page.goml
Rollup merge of #103190 - fmease:rustdoc-render-bounds-of-cross-crate-gat-params...
[rust.git] / src / test / rustdoc-gui / help-page.goml
1 // This test ensures that opening the help page in its own tab works.
2 goto: "file://" + |DOC_PATH| + "/help.html"
3 size: (1000, 1000) // Try desktop size first.
4 wait-for: "#help"
5 assert-css: ("#help", {"display": "block"})
6 click: "#help-button > a"
7 assert-css: ("#help", {"display": "block"})
8 compare-elements-property: (".sub", "#help", ["offsetWidth"])
9 compare-elements-position: (".sub", "#help", ("x"))
10 size: (500, 1000) // Try mobile next.
11 assert-css: ("#help", {"display": "block"})
12 compare-elements-property: (".sub", "#help", ["offsetWidth"])
13 compare-elements-position: (".sub", "#help", ("x"))
14
15 // This test ensures that opening the help popover without switching pages works.
16 goto: "file://" + |DOC_PATH| + "/test_docs/index.html"
17 size: (1000, 1000) // Only supported on desktop.
18 assert-false: "#help"
19 click: "#help-button > a"
20 assert-css: ("#help", {"display": "block"})
21 click: "#help-button > a"
22 assert-css: ("#help", {"display": "none"})
23 compare-elements-property-false: (".sub", "#help", ["offsetWidth"])
24 compare-elements-position-false: (".sub", "#help", ("x"))