fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
1.2 KiB31 linesraw
1// This test ensures that the "item-info" elements don't overflow.
2go-to: "file://" + |DOC_PATH| + "/lib2/struct.LongItemInfo.html"
3// We set a fixed size so there is no chance of "random" resize.
4set-window-size: (1200, 870)
5// Logically, the "item-decl" and the "item-info" should have the same scroll width.
6compare-elements-property: (".item-decl", ".item-info", ["scrollWidth"])
7assert-property: (".item-info", {"scrollWidth": "940"})
8// Just to be sure we're comparing the correct "item-info":
9assert-text: (
10    ".item-info",
11    "Available on Android or Linux or Emscripten or DragonFly BSD",
12    STARTS_WITH,
13)
14
15// Checking the "item-info" on an impl block as well:
16go-to: "file://" + |DOC_PATH| + "/lib2/struct.LongItemInfo2.html"
17compare-elements-property: (
18    "#impl-SimpleTrait-for-LongItemInfo2 .item-info",
19    "#impl-SimpleTrait-for-LongItemInfo2 + .docblock",
20    ["scrollWidth"],
21)
22assert-property: (
23    "#impl-SimpleTrait-for-LongItemInfo2 .item-info",
24    {"scrollWidth": "916"},
25)
26// Just to be sure we're comparing the correct "item-info":
27assert-text: (
28    "#impl-SimpleTrait-for-LongItemInfo2 .item-info",
29    "Available on Android or Linux or Emscripten or DragonFly BSD",
30    STARTS_WITH,
31)