diff options
| author | Guillaume Gomez <guillaume.gomez@huawei.com> | 2022-07-25 14:35:06 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume.gomez@huawei.com> | 2022-07-25 14:35:06 +0200 |
| commit | 8db7249f26ef4265ae58bb77d8f3559b723134c9 (patch) | |
| tree | 24caff3dfeb3ba0dbb643dd1bdebff89e1b0ce78 /src | |
| parent | 202e32a2cadda874a908c148f9e7674f81858612 (diff) | |
| download | rust-8db7249f26ef4265ae58bb77d8f3559b723134c9.tar.gz rust-8db7249f26ef4265ae58bb77d8f3559b723134c9.zip | |
Add GUI test to prevent sidebar background regression
Diffstat (limited to 'src')
| -rw-r--r-- | src/test/rustdoc-gui/sidebar-mobile.goml | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/test/rustdoc-gui/sidebar-mobile.goml b/src/test/rustdoc-gui/sidebar-mobile.goml index 79f18db8fc7..033c6578349 100644 --- a/src/test/rustdoc-gui/sidebar-mobile.goml +++ b/src/test/rustdoc-gui/sidebar-mobile.goml @@ -40,3 +40,25 @@ assert-position: ("#method\.must_use", {"y": 45}) click: ".sidebar-menu-toggle" scroll-to: ".block.keyword li:nth-child(1)" compare-elements-position-near: (".block.keyword li:nth-child(1)", ".mobile-topbar", {"y": 543}) + +// Now checking the background color of the sidebar. +local-storage: {"rustdoc-use-system-theme": "false", "rustdoc-theme": "dark"} +reload: + +// Open the sidebar menu. +click: ".sidebar-menu-toggle" +assert-css: (".sidebar", {"background-color": "rgb(80, 80, 80)"}) + +local-storage: {"rustdoc-use-system-theme": "false", "rustdoc-theme": "ayu"} +reload: + +// Open the sidebar menu. +click: ".sidebar-menu-toggle" +assert-css: (".sidebar", {"background-color": "rgb(20, 25, 31)"}) + +local-storage: {"rustdoc-use-system-theme": "false", "rustdoc-theme": "light"} +reload: + +// Open the sidebar menu. +click: ".sidebar-menu-toggle" +assert-css: (".sidebar", {"background-color": "rgb(245, 245, 245)"}) |
