]> git.lizzy.rs Git - rust.git/blob - src/test/rustdoc-gui/theme-change.goml
Rollup merge of #93358 - compiler-errors:is-not-const, r=fee1-dead
[rust.git] / src / test / rustdoc-gui / theme-change.goml
1 // Ensures that the theme change is working as expected.
2 goto: file://|DOC_PATH|/test_docs/index.html
3 click: "#theme-picker"
4 click: "#theme-choices > button:first-child"
5 wait-for: 500
6 // should be the ayu theme so let's check the color
7 assert-css: ("body", { "background-color": "rgb(15, 20, 25)" })
8 click: "#theme-choices > button:last-child"
9 wait-for: 500
10 // should be the light theme so let's check the color
11 assert-css: ("body", { "background-color": "rgb(255, 255, 255)" })
12
13 goto: file://|DOC_PATH|/settings.html
14 click: "#theme-light"
15 wait-for: 500
16 assert-css: ("body", { "background-color": "rgb(255, 255, 255)" })
17 assert-local-storage: { "rustdoc-theme": "light" }
18
19 click: "#theme-dark"
20 wait-for: 500
21 assert-css: ("body", { "background-color": "rgb(53, 53, 53)" })
22 assert-local-storage: { "rustdoc-theme": "dark" }
23
24 click: "#theme-ayu"
25 wait-for: 500
26 assert-css: ("body", { "background-color": "rgb(15, 20, 25)" })
27 assert-local-storage: { "rustdoc-theme": "ayu" }