Skip to content

Commit

Permalink
Rollup merge of #115244 - GuillaumeGomez:migrate-gui-test-color-36, r…
Browse files Browse the repository at this point in the history
…=notriddle

Migrate GUI colors test to original CSS color format

Follow-up of #111459.

r? `@notriddle`
  • Loading branch information
matthiaskrgr authored Aug 26, 2023
2 parents b578e86 + a448468 commit f0bbc25
Showing 1 changed file with 9 additions and 12 deletions.
21 changes: 9 additions & 12 deletions tests/rustdoc-gui/warning-block.goml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ show-text: true

define-function: (
"check-warning",
(theme, color, border_color, background_color),
(theme, color, border_color),
block {
set-local-storage: {"rustdoc-theme": |theme|, "rustdoc-use-system-theme": "false"}
reload:
Expand All @@ -14,32 +14,29 @@ define-function: (
"margin-bottom": "12px",
"color": |color|,
"border-left": "2px solid " + |border_color|,
"background-color": |background_color|,
"background-color": "transparent",
})
assert-css: ("#doc-warning-2", {
"margin-bottom": "0px",
"color": |color|,
"border-left": "2px solid " + |border_color|,
"background-color": |background_color|,
"background-color": "transparent",
})
},
)

call-function: ("check-warning", {
"theme": "ayu",
"color": "rgb(197, 197, 197)",
"border_color": "rgb(255, 142, 0)",
"background_color": "rgba(0, 0, 0, 0)",
"color": "#c5c5c5",
"border_color": "#ff8e00",
})
call-function: ("check-warning", {
"theme": "dark",
"color": "rgb(221, 221, 221)",
"border_color": "rgb(255, 142, 0)",
"background_color": "rgba(0, 0, 0, 0)",
"color": "#ddd",
"border_color": "#ff8e00",
})
call-function: ("check-warning", {
"theme": "light",
"color": "rgb(0, 0, 0)",
"border_color": "rgb(255, 142, 0)",
"background_color": "rgba(0, 0, 0, 0)",
"color": "black",
"border_color": "#ff8e00",
})

0 comments on commit f0bbc25

Please sign in to comment.