diff options
| author | Yuki Okushi <jtitor@2k36.org> | 2022-05-18 07:41:00 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-05-18 07:41:00 +0900 |
| commit | b8dd27079c93d71f9667edbe17d0037c32c299af (patch) | |
| tree | 284d143011d5442694cb9c120d175e416d967dae /src/test | |
| parent | 7361b22b4c57a446e042f8cbc95e17969a7301eb (diff) | |
| parent | 440bbce36d649a973a323ed5fd431e36f124fb59 (diff) | |
| download | rust-b8dd27079c93d71f9667edbe17d0037c32c299af.tar.gz rust-b8dd27079c93d71f9667edbe17d0037c32c299af.zip | |
Rollup merge of #97113 - GuillaumeGomez:search-ui-fixes, r=notriddle
Search GUI fixes The first fix is about the duplicated "in":  The second fix is about the `<select>` broken style:   You can test it [here](https://rustdoc.crud.net/imperio/search-ui-fixes/doc/foo/index.html?search=test). r? `@notriddle`
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/rustdoc-gui/search-filter.goml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/src/test/rustdoc-gui/search-filter.goml b/src/test/rustdoc-gui/search-filter.goml index aca8390dfb3..d0b3175114c 100644 --- a/src/test/rustdoc-gui/search-filter.goml +++ b/src/test/rustdoc-gui/search-filter.goml @@ -45,3 +45,37 @@ goto: file://|DOC_PATH|/test_docs/index.html?search=test&filter-crate=lib2 wait-for: "#crate-search" assert-property: ("#crate-search", {"value": "lib2"}) assert-false: "#results .externcrate" + +// Checking that the text for the "title" is correct (the "All" comes from the "<select>"). +assert-text: ("#search-settings", "Results for test in All", STARTS_WITH) + +// Checking the display of the crate filter. +// We start with the light theme. +local-storage: {"rustdoc-theme": "light", "rustdoc-use-system-theme": "false"} +reload: + +timeout: 2000 +wait-for: "#crate-search" +assert-css: ("#crate-search", { + "border": "1px solid rgb(224, 224, 224)", + "color": "rgb(0, 0, 0)", + "background-color": "rgb(255, 255, 255)", +}) + +// We now check the dark theme. +click: "#settings-menu" +wait-for: "#settings" +click: "#theme-dark" +wait-for-css: ("#crate-search", { + "border": "1px solid rgb(240, 240, 240)", + "color": "rgb(17, 17, 17)", + "background-color": "rgb(240, 240, 240)", +}) + +// And finally we check the ayu theme. +click: "#theme-ayu" +wait-for-css: ("#crate-search", { + "border": "1px solid rgb(66, 76, 87)", + "color": "rgb(197, 197, 197)", + "background-color": "rgb(20, 25, 32)", +}) |
