diff options
| author | Guillaume Gomez <guillaume.gomez@huawei.com> | 2024-04-05 21:38:55 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume.gomez@huawei.com> | 2024-04-05 21:38:55 +0200 |
| commit | 7659ef47f03f4e2bbbef65856427add98f898ef5 (patch) | |
| tree | f2069567de13688a16cd07f8e61a75cf0f0da14f /tests/rustdoc-gui/sidebar-source-code-display.goml | |
| parent | 5958f5e08fa88ee95ede8c00f1b89befe0372d54 (diff) | |
| download | rust-7659ef47f03f4e2bbbef65856427add98f898ef5.tar.gz rust-7659ef47f03f4e2bbbef65856427add98f898ef5.zip | |
Use `include` command to reduce code duplication
Diffstat (limited to 'tests/rustdoc-gui/sidebar-source-code-display.goml')
| -rw-r--r-- | tests/rustdoc-gui/sidebar-source-code-display.goml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/rustdoc-gui/sidebar-source-code-display.goml b/tests/rustdoc-gui/sidebar-source-code-display.goml index 41c8e45f4a6..3bfbe820b8d 100644 --- a/tests/rustdoc-gui/sidebar-source-code-display.goml +++ b/tests/rustdoc-gui/sidebar-source-code-display.goml @@ -1,4 +1,5 @@ // This test ensures that the elements in the sidebar are displayed correctly. +include: "utils.goml" javascript: false go-to: "file://" + |DOC_PATH| + "/src/test_docs/lib.rs.html" // Since the javascript is disabled, there shouldn't be a toggle. @@ -34,8 +35,7 @@ define-function: ( theme, color, color_hover, background, background_hover, background_toggle, ], block { - set-local-storage: {"rustdoc-theme": |theme|, "rustdoc-use-system-theme": "false"} - reload: + call-function: ("switch-theme", {"theme": |theme|}) wait-for-css: (".src .sidebar > *", {"visibility": "visible"}) assert-css: ( "#src-sidebar details[open] > .files a.selected", |
