2021-07-10 19:10:14 +00:00
|
|
|
// The goal of this test is to check that the external trait implementors, generated with JS,
|
|
|
|
// have the same display than the "local" ones.
|
|
|
|
goto: file://|DOC_PATH|/implementors/trait.Whatever.html
|
|
|
|
assert: "#implementors-list"
|
|
|
|
// There are supposed to be two implementors listed.
|
2021-08-30 14:47:17 +00:00
|
|
|
assert-count: ("#implementors-list .impl", 2)
|
2021-07-10 19:10:14 +00:00
|
|
|
// Now we check that both implementors have an anchor, an ID and a similar DOM.
|
2021-08-30 14:47:17 +00:00
|
|
|
assert: ("#implementors-list .impl:nth-child(1) > a.anchor")
|
|
|
|
assert-attribute: ("#implementors-list .impl:nth-child(1)", {"id": "impl-Whatever"})
|
|
|
|
assert-attribute: ("#implementors-list .impl:nth-child(1) > a.anchor", {"href": "#impl-Whatever"})
|
|
|
|
assert: "#implementors-list .impl:nth-child(1) > .code-header.in-band"
|
2021-07-10 19:10:14 +00:00
|
|
|
|
2021-08-30 14:47:17 +00:00
|
|
|
assert: ("#implementors-list .impl:nth-child(2) > a.anchor")
|
|
|
|
assert-attribute: ("#implementors-list .impl:nth-child(2)", {"id": "impl-Whatever-1"})
|
|
|
|
assert-attribute: ("#implementors-list .impl:nth-child(2) > a.anchor", {"href": "#impl-Whatever-1"})
|
|
|
|
assert: "#implementors-list .impl:nth-child(2) > .code-header.in-band"
|
2022-02-08 06:36:51 +00:00
|
|
|
|
|
|
|
goto: file://|DOC_PATH|/test_docs/struct.HasEmptyTraits.html
|
|
|
|
compare-elements-position-near-false: ("#impl-EmptyTrait1", "#impl-EmptyTrait2", {"y": 30})
|
|
|
|
compare-elements-position-near: ("#impl-EmptyTrait3 h3", "#impl-EmptyTrait3 .item-info", {"y": 30})
|