Skip to content

Commit 9543636

Browse files
committed
Auto merge of #86468 - GuillaumeGomez:update-browser-ui-test-version, r=jsha
Update browser-ui-test version It greatly improves the test readability (thanks to `@jsha` for the suggestions!). r? `@jsha`
2 parents 192920c + 1e222ba commit 9543636

21 files changed

+101
-101
lines changed

src/ci/docker/host-x86_64/x86_64-gnu-tools/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ ENV PATH="/node-v14.4.0-linux-x64/bin:${PATH}"
7171
# https://github.com/puppeteer/puppeteer/issues/375
7272
#
7373
# We also specify the version in case we need to update it to go around cache limitations.
74-
RUN npm install -g browser-ui-test@0.2.14 --unsafe-perm=true
74+
RUN npm install -g browser-ui-test@0.3.0 --unsafe-perm=true
7575

7676
ENV RUST_CONFIGURE_ARGS \
7777
--build=x86_64-unknown-linux-gnu \

src/test/rustdoc-gui/basic-code.goml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
goto: file://|DOC_PATH|/test_docs/index.html
22
click: ".srclink"
3-
assert: (".line-numbers", 1)
3+
assert-count: (".line-numbers", 1)

src/test/rustdoc-gui/check_info_sign_position.goml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ goto: file://|DOC_PATH|/test_docs/index.html
22
goto: ./fn.check_list_code_block.html
33
// If the codeblock is the first element of the docblock, the information tooltip must have
44
// have some top margin to avoid going over the toggle (the "[+]").
5-
assert: (".docblock > .information > .compile_fail", { "margin-top": "16px" })
5+
assert-css: (".docblock > .information > .compile_fail", { "margin-top": "16px" })
66
// Checks that the other codeblocks don't have this top margin.
7-
assert: ("ol > li > .information > .compile_fail", { "margin-top": "0px" })
8-
assert: ("ol > li > .information > .ignore", { "margin-top": "0px" })
9-
assert: (".docblock > .information > .ignore", { "margin-top": "0px" })
7+
assert-css: ("ol > li > .information > .compile_fail", { "margin-top": "0px" })
8+
assert-css: ("ol > li > .information > .ignore", { "margin-top": "0px" })
9+
assert-css: (".docblock > .information > .ignore", { "margin-top": "0px" })

src/test/rustdoc-gui/code-sidebar-toggle.goml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ click: ".srclink"
33
click: "#sidebar-toggle"
44
wait-for: 500
55
fail: true
6-
assert: ("#source-sidebar", { "left": "-300px" })
6+
assert-css: ("#source-sidebar", { "left": "-300px" })

src/test/rustdoc-gui/escape-key.goml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,25 +2,25 @@ goto: file://|DOC_PATH|/test_docs/index.html
22
// First, we check that the search results are hidden when the Escape key is pressed.
33
write: (".search-input", "test")
44
wait-for: "#search > h1" // The search element is empty before the first search
5-
assert: ("#search", "class", "content")
6-
assert: ("#main", "class", "content hidden")
5+
assert-attr: ("#search", {"class": "content"})
6+
assert-attr: ("#main", {"class": "content hidden"})
77
press-key: "Escape"
8-
assert: ("#search", "class", "content hidden")
9-
assert: ("#main", "class", "content")
8+
assert-attr: ("#search", {"class": "content hidden"})
9+
assert-attr: ("#main", {"class": "content"})
1010

1111
// Check that focusing the search input brings back the search results
1212
focus: ".search-input"
13-
assert: ("#search", "class", "content")
14-
assert: ("#main", "class", "content hidden")
13+
assert-attr: ("#search", {"class": "content"})
14+
assert-attr: ("#main", {"class": "content hidden"})
1515

1616
// Now let's check that when the help popup is displayed and we press Escape, it doesn't
1717
// hide the search results too.
1818
click: "#help-button"
19-
assert: ("#help", "class", "")
19+
assert-attr: ("#help", {"class": ""})
2020
press-key: "Escape"
21-
assert: ("#help", "class", "hidden")
22-
assert: ("#search", "class", "content")
23-
assert: ("#main", "class", "content hidden")
21+
assert-attr: ("#help", {"class": "hidden"})
22+
assert-attr: ("#search", {"class": "content"})
23+
assert-attr: ("#main", {"class": "content hidden"})
2424

2525
// Check that Escape hides the search results when a search result is focused.
2626
focus: ".search-input"
@@ -29,6 +29,6 @@ press-key: "ArrowDown"
2929
assert-false: ".search-input:focus"
3030
assert: "#results a:focus"
3131
press-key: "Escape"
32-
assert: ("#help", "class", "hidden")
33-
assert: ("#search", "class", "content hidden")
34-
assert: ("#main", "class", "content")
32+
assert-attr: ("#help", {"class": "hidden"})
33+
assert-attr: ("#search", {"class": "content hidden"})
34+
assert-attr: ("#main", {"class": "content"})

src/test/rustdoc-gui/font-weight.goml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
goto: file://|DOC_PATH|/lib2/struct.Foo.html
22
// This test checks that the font weight is correctly applied.
3-
assert: ("//*[@class='docblock type-decl']//a[text()='Alias']", {"font-weight": "400"})
4-
assert: ("//*[@class='structfield small-section-header']//a[text()='Alias']", {"font-weight": "400"})
5-
assert: ("#method\.a_method > code", {"font-weight": "600"})
6-
assert: ("#associatedtype\.X > code", {"font-weight": "600"})
7-
assert: ("#associatedconstant\.Y > code", {"font-weight": "600"})
3+
assert-css: ("//*[@class='docblock type-decl']//a[text()='Alias']", {"font-weight": "400"})
4+
assert-css: ("//*[@class='structfield small-section-header']//a[text()='Alias']", {"font-weight": "400"})
5+
assert-css: ("#method\.a_method > code", {"font-weight": "600"})
6+
assert-css: ("#associatedtype\.X > code", {"font-weight": "600"})
7+
assert-css: ("#associatedconstant\.Y > code", {"font-weight": "600"})
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
// This test ensures that the element corresponding to the hash is displayed.
22
goto: file://|DOC_PATH|/test_docs/struct.Foo.html#method.borrow
33
// In the blanket implementations list, "Borrow" is the second one, hence the ":nth(2)".
4-
assert: ("#blanket-implementations-list > details:nth-child(2)", "open", "")
4+
assert-attr: ("#blanket-implementations-list > details:nth-child(2)", {"open": ""})
55
// We first check that the impl block is open by default.
6-
assert: ("#implementations + details", "open", "")
6+
assert-attr: ("#implementations + details", {"open": ""})
77
// We collapse it.
88
click: "#implementations + details > summary"
99
// We check that it was collapsed as expected.
10-
assert-false: ("#implementations + details", "open", "")
10+
assert-attr-false: ("#implementations + details", {"open": ""})
1111
// To ensure that we will click on the currently hidden method.
12-
assert: (".sidebar-links > a", "must_use")
12+
assert-text: (".sidebar-links > a", "must_use")
1313
click: ".sidebar-links > a"
1414
// We check that the impl block was opened as expected so that we can see the method.
15-
assert: ("#implementations + details", "open", "")
15+
assert-attr: ("#implementations + details", {"open": ""})
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// This test ensures that the impl blocks are open by default.
22
goto: file://|DOC_PATH|/test_docs/struct.Foo.html
3-
assert: ("#main > details.implementors-toggle", "open", "")
3+
assert-attr: ("#main > details.implementors-toggle", {"open": ""})

src/test/rustdoc-gui/search-result-colors.goml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@ write: (".search-input", "thisisanalias")
1010
// Waiting for the search results to appear...
1111
wait-for: "#titles"
1212
// Checking that the colors for the alias element are the ones expected.
13-
assert: (".result-name > .alias", {"color": "rgb(255, 255, 255)"})
14-
assert: (".result-name > .alias > .grey", {"color": "rgb(204, 204, 204)"})
13+
assert-css: (".result-name > .alias", {"color": "rgb(255, 255, 255)"})
14+
assert-css: (".result-name > .alias > .grey", {"color": "rgb(204, 204, 204)"})

src/test/rustdoc-gui/search-result-description.goml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
goto: file://|DOC_PATH|/test_docs/index.html?search=some_more_function
33
// Waiting for the search results to appear...
44
wait-for: "#titles"
5-
assert: (".search-results .desc code", "format!")
5+
assert-text: (".search-results .desc code", "format!")

src/test/rustdoc-gui/search-result-display.goml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ write: (".search-input", "test")
55
wait-for: "#titles"
66
// The width is returned by "getComputedStyle" which returns the exact number instead of the
77
// CSS rule which is "50%"...
8-
assert: (".search-results div.desc", {"width": "320px"})
8+
assert-css: (".search-results div.desc", {"width": "320px"})
99
size: (600, 100)
1010
// As counter-intuitive as it may seem, in this width, the width is "100%", which is why
1111
// when computed it's larger.
12-
assert: (".search-results div.desc", {"width": "570px"})
12+
assert-css: (".search-results div.desc", {"width": "570px"})

src/test/rustdoc-gui/search-result-keyword.goml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ wait-for: "#titles"
66
// less good.
77
//
88
// Checking that the CSS is displaying " (keyword)" in italic.
9-
assert: (".result-name span.keyword > i", "(keyword)")
10-
assert: (".result-name span.keyword", "CookieMonster (keyword)")
9+
assert-text: (".result-name span.keyword > i", "(keyword)")
10+
assert-text: (".result-name span.keyword", "CookieMonster (keyword)")

src/test/rustdoc-gui/search-tab-selection-if-current-is-empty.goml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,20 @@ goto: file://|DOC_PATH|/test_docs/index.html
22
write: (".search-input", "Foo")
33
// Waiting for the search results to appear...
44
wait-for: "#titles"
5-
assert: ("#titles > button:nth-of-type(1)", "class", "selected")
5+
assert-attr: ("#titles > button:nth-of-type(1)", {"class": "selected"})
66

77
// To go back to the original "state"
88
goto: file://|DOC_PATH|/test_docs/index.html
99
write: (".search-input", "-> String")
1010
// Waiting for the search results to appear...
1111
wait-for: "#titles"
1212
// With this search, only the last tab shouldn't be empty so it should be selected.
13-
assert: ("#titles > button:nth-of-type(3)", "class", "selected")
13+
assert-attr: ("#titles > button:nth-of-type(3)", {"class": "selected"})
1414

1515
// To go back to the original "state"
1616
goto: file://|DOC_PATH|/test_docs/index.html
1717
write: (".search-input", "-> Something")
1818
// Waiting for the search results to appear...
1919
wait-for: "#titles"
2020
// With this search, all the tabs are empty so the first one should remain selected.
21-
assert: ("#titles > button:nth-of-type(1)", "class", "selected")
21+
assert-attr: ("#titles > button:nth-of-type(1)", {"class": "selected"})

src/test/rustdoc-gui/shortcuts.goml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,19 @@ press-key: "Escape"
88
assert-false: "input.search-input:focus"
99
// We now check for the help popup.
1010
press-key: "?"
11-
assert: ("#help", {"display": "flex"})
11+
assert-css: ("#help", {"display": "flex"})
1212
assert-false: "#help.hidden"
1313
press-key: "Escape"
14-
assert: ("#help.hidden", {"display": "none"})
14+
assert-css: ("#help.hidden", {"display": "none"})
1515
// Check for the themes list.
16-
assert: ("#theme-choices", {"display": "none"})
16+
assert-css: ("#theme-choices", {"display": "none"})
1717
press-key: "t"
18-
assert: ("#theme-choices", {"display": "block"})
18+
assert-css: ("#theme-choices", {"display": "block"})
1919
press-key: "t"
2020
// We ensure that 't' hides back the menu.
21-
assert: ("#theme-choices", {"display": "none"})
21+
assert-css: ("#theme-choices", {"display": "none"})
2222
press-key: "t"
23-
assert: ("#theme-choices", {"display": "block"})
23+
assert-css: ("#theme-choices", {"display": "block"})
2424
press-key: "Escape"
2525
// We ensure that 'Escape' hides the menu too.
26-
assert: ("#theme-choices", {"display": "none"})
26+
assert-css: ("#theme-choices", {"display": "none"})

src/test/rustdoc-gui/sidebar.goml

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
goto: file://|DOC_PATH|/test_docs/index.html
2-
assert: (".sidebar > .location", "Crate test_docs")
2+
assert-text: (".sidebar > .location", "Crate test_docs")
33
// In modules, we only have one "location" element.
4-
assert: (".sidebar .location", 1)
5-
assert: (".sidebar-elems > #all-types", "See all test_docs's items")
4+
assert-count: (".sidebar .location", 1)
5+
assert-text: (".sidebar-elems > #all-types", "See all test_docs's items")
66
// We check that we have the crates list and that the "current" on is "test_docs".
7-
assert: (".sidebar-elems > .crate > ul > li > a.current", "test_docs")
7+
assert-text: (".sidebar-elems > .crate > ul > li > a.current", "test_docs")
88
// And we're also supposed to have the list of items in the current module.
9-
assert: (".sidebar-elems > .items > ul > li:nth-child(1)", "Modules")
10-
assert: (".sidebar-elems > .items > ul > li:nth-child(2)", "Structs")
11-
assert: (".sidebar-elems > .items > ul > li:nth-child(3)", "Enums")
12-
assert: (".sidebar-elems > .items > ul > li:nth-child(4)", "Traits")
13-
assert: (".sidebar-elems > .items > ul > li:nth-child(5)", "Functions")
14-
assert: (".sidebar-elems > .items > ul > li:nth-child(6)", "Type Definitions")
15-
assert: (".sidebar-elems > .items > ul > li:nth-child(7)", "Keywords")
16-
assert: ("#structs + table td > a", "Foo")
9+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(1)", "Modules")
10+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(2)", "Structs")
11+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(3)", "Enums")
12+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(4)", "Traits")
13+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(5)", "Functions")
14+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(6)", "Type Definitions")
15+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(7)", "Keywords")
16+
assert-text: ("#structs + table td > a", "Foo")
1717
click: "#structs + table td > a"
1818

1919
// PAGE: struct.Foo.html
20-
assert: (".sidebar .location", 2)
20+
assert-count: (".sidebar .location", 2)
2121
// We check that there is no crate listed outside of the top level.
2222
assert-false: ".sidebar-elems > .crate"
2323
// We now go back to the crate page to click on the "lib2" crate link.
@@ -26,35 +26,35 @@ click: ".sidebar-elems > .crate > ul > li:first-child > a"
2626

2727
// PAGE: lib2/index.html
2828
goto: file://|DOC_PATH|/lib2/index.html
29-
assert: (".sidebar > .location", "Crate lib2")
29+
assert-text: (".sidebar > .location", "Crate lib2")
3030
// We check that we have the crates list and that the "current" on is now "lib2".
31-
assert: (".sidebar-elems > .crate > ul > li > a.current", "lib2")
31+
assert-text: (".sidebar-elems > .crate > ul > li > a.current", "lib2")
3232
// We now go to the "foobar" function page.
33-
assert: (".sidebar-elems > .items > ul > li:nth-child(1)", "Modules")
34-
assert: (".sidebar-elems > .items > ul > li:nth-child(2)", "Structs")
35-
assert: (".sidebar-elems > .items > ul > li:nth-child(3)", "Traits")
36-
assert: (".sidebar-elems > .items > ul > li:nth-child(4)", "Functions")
37-
assert: (".sidebar-elems > .items > ul > li:nth-child(5)", "Type Definitions")
38-
assert: ("#functions + table td > a", "foobar")
33+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(1)", "Modules")
34+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(2)", "Structs")
35+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(3)", "Traits")
36+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(4)", "Functions")
37+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(5)", "Type Definitions")
38+
assert-text: ("#functions + table td > a", "foobar")
3939
click: "#functions + table td > a"
4040

4141
// PAGE: fn.foobar.html
4242
// In items containing no items (like functions or constants) and in modules, we have one
4343
// "location" elements.
44-
assert: (".sidebar .location", 1)
44+
assert-count: (".sidebar .location", 1)
4545
// There is a "<br>" tag between "in" and "lib2", but it doesn't count as a space.
46-
assert: (".sidebar .sidebar-elems .location", "Other items inlib2")
46+
assert-text: (".sidebar .sidebar-elems .location", "Other items inlib2")
4747
// We check that we don't have the crate list.
4848
assert-false: ".sidebar-elems > .crate"
4949

5050
goto: ./module/index.html
51-
assert: (".sidebar > .location", "Module module")
51+
assert-text: (".sidebar > .location", "Module module")
5252
// We check that we don't have the crate list.
5353
assert-false: ".sidebar-elems > .crate"
5454

5555
goto: ./sub_module/sub_sub_module/index.html
56-
assert: (".sidebar > .location", "Module sub_sub_module")
56+
assert-text: (".sidebar > .location", "Module sub_sub_module")
5757
// We check that we don't have the crate list.
5858
assert-false: ".sidebar-elems > .crate"
59-
assert: (".sidebar-elems > .items > ul > li:nth-child(1)", "Functions")
60-
assert: ("#functions + table td > a", "foo")
59+
assert-text: (".sidebar-elems > .items > ul > li:nth-child(1)", "Functions")
60+
assert-text: ("#functions + table td > a", "foo")

src/test/rustdoc-gui/source-code-page.goml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ goto: file://|DOC_PATH|/src/test_docs/lib.rs.html
33
click: (40, 224) // This is the position of the span for line 4.
44
// Unfortunately, "#4" isn't a valid query selector, so we have to go around that limitation
55
// by instead getting the nth span.
6-
assert: (".line-numbers > span:nth-child(4)", "class", "line-highlighted")
6+
assert-attr: (".line-numbers > span:nth-child(4)", {"class": "line-highlighted"})
77
// We now check that the good spans are highlighted
88
goto: file://|DOC_PATH|/src/test_docs/lib.rs.html#4-6
9-
assert-false: (".line-numbers > span:nth-child(3)", "class", "line-highlighted")
10-
assert: (".line-numbers > span:nth-child(4)", "class", "line-highlighted")
11-
assert: (".line-numbers > span:nth-child(5)", "class", "line-highlighted")
12-
assert: (".line-numbers > span:nth-child(6)", "class", "line-highlighted")
13-
assert-false: (".line-numbers > span:nth-child(7)", "class", "line-highlighted")
9+
assert-attr-false: (".line-numbers > span:nth-child(3)", {"class": "line-highlighted"})
10+
assert-attr: (".line-numbers > span:nth-child(4)", {"class": "line-highlighted"})
11+
assert-attr: (".line-numbers > span:nth-child(5)", {"class": "line-highlighted"})
12+
assert-attr: (".line-numbers > span:nth-child(6)", {"class": "line-highlighted"})
13+
assert-attr-false: (".line-numbers > span:nth-child(7)", {"class": "line-highlighted"})

src/test/rustdoc-gui/theme-change.goml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ click: "#theme-picker"
33
click: "#theme-choices > button:first-child"
44
wait-for: 500
55
// should be the ayu theme so let's check the color
6-
assert: ("body", { "background-color": "rgb(15, 20, 25)" })
6+
assert-css: ("body", { "background-color": "rgb(15, 20, 25)" })
77
click: "#theme-choices > button:last-child"
88
wait-for: 500
99
// should be the light theme so let's check the color
10-
assert: ("body", { "background-color": "rgb(255, 255, 255)" })
10+
assert-css: ("body", { "background-color": "rgb(255, 255, 255)" })
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
goto: file://|DOC_PATH|/test_docs/struct.Foo.html
22
size: (433, 600)
3-
assert: (".top-doc", "open", "")
3+
assert-attr: (".top-doc", {"open": ""})
44
click: (4, 280) // This is the position of the top doc comment toggle
5-
assert-false: (".top-doc", "open", "")
5+
assert-attr-false: (".top-doc", {"open": ""})
66
click: (4, 280)
7-
assert: (".top-doc", "open", "")
7+
assert-attr: (".top-doc", {"open": ""})
88
// To ensure that the toggle isn't over the text, we check that the toggle isn't clicked.
99
click: (3, 280)
10-
assert: (".top-doc", "open", "")
10+
assert-attr: (".top-doc", {"open": ""})
1111

1212
// Now we do the same but with a little bigger width
1313
size: (600, 600)
14-
assert: (".top-doc", "open", "")
14+
assert-attr: (".top-doc", {"open": ""})
1515
click: (4, 240) // New Y position since all search elements are back on one line.
16-
assert-false: (".top-doc", "open", "")
16+
assert-attr-false: (".top-doc", {"open": ""})
1717
click: (4, 240)
18-
assert: (".top-doc", "open", "")
18+
assert-attr: (".top-doc", {"open": ""})
1919
// To ensure that the toggle isn't over the text, we check that the toggle isn't clicked.
2020
click: (3, 240)
21-
assert: (".top-doc", "open", "")
21+
assert-attr: (".top-doc", {"open": ""})

src/test/rustdoc-gui/toggle-docs.goml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
goto: file://|DOC_PATH|/test_docs/index.html
2-
assert: ("#main > details.top-doc", "open", "")
2+
assert-attr: ("#main > details.top-doc", {"open": ""})
33
click: "#toggle-all-docs"
44
wait-for: 1000
55
// This is now collapsed so there shouldn't be the "open" attribute on details.
6-
assert-false: ("#main > details.top-doc", "open", "")
6+
assert-attr-false: ("#main > details.top-doc", {"open": ""})
77
click: "#toggle-all-docs"
88
wait-for: 1000
99
// Not collapsed anymore so the "open" attribute should be back.
10-
assert: ("#main > details.top-doc", "open", "")
10+
assert-attr: ("#main > details.top-doc", {"open": ""})

src/test/rustdoc-gui/toggled-open-implementations.goml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
// has all the implementations toggled open by default, so users can
33
// find method names in those implementations with Ctrl-F.
44
goto: file://|DOC_PATH|/test_docs/struct.Foo.html
5-
assert: (".rustdoc-toggle.implementors-toggle", "open", "")
5+
assert-attr: (".rustdoc-toggle.implementors-toggle", {"open": ""})
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
goto: file://|DOC_PATH|/test_docs/trait.AnotherOne.html
2-
assert: (".sidebar-links a:nth-of-type(1)", "another")
3-
assert: (".sidebar-links a:nth-of-type(2)", "func1")
4-
assert: (".sidebar-links a:nth-of-type(3)", "func2")
5-
assert: (".sidebar-links a:nth-of-type(4)", "func3")
6-
assert: (".sidebar-links a:nth-of-type(5)", "hello")
7-
assert: (".sidebar-links a:nth-of-type(6)", "why_not")
2+
assert-text: (".sidebar-links a:nth-of-type(1)", "another")
3+
assert-text: (".sidebar-links a:nth-of-type(2)", "func1")
4+
assert-text: (".sidebar-links a:nth-of-type(3)", "func2")
5+
assert-text: (".sidebar-links a:nth-of-type(4)", "func3")
6+
assert-text: (".sidebar-links a:nth-of-type(5)", "hello")
7+
assert-text: (".sidebar-links a:nth-of-type(6)", "why_not")

0 commit comments

Comments
 (0)