2022-11-19 18:42:07 -06:00
|
|
|
goto: "file://" + |DOC_PATH| + "/scrape_examples/fn.test.html"
|
2022-11-26 23:27:10 -06:00
|
|
|
|
2022-12-06 01:34:02 -06:00
|
|
|
// The next/prev buttons vertically scroll the code viewport between examples
|
2022-11-26 23:27:10 -06:00
|
|
|
store-property: (initialScrollTop, ".scraped-example-list > .scraped-example pre", "scrollTop")
|
|
|
|
focus: ".scraped-example-list > .scraped-example .next"
|
|
|
|
press-key: "Enter"
|
|
|
|
assert-property-false: (".scraped-example-list > .scraped-example pre", {
|
2023-01-08 14:29:57 -06:00
|
|
|
"scrollTop": |initialScrollTop|
|
2022-11-26 23:27:10 -06:00
|
|
|
})
|
|
|
|
focus: ".scraped-example-list > .scraped-example .prev"
|
|
|
|
press-key: "Enter"
|
|
|
|
assert-property: (".scraped-example-list > .scraped-example pre", {
|
2023-01-08 14:29:57 -06:00
|
|
|
"scrollTop": |initialScrollTop|
|
2022-11-26 23:27:10 -06:00
|
|
|
})
|
|
|
|
|
2022-12-06 01:34:02 -06:00
|
|
|
// The expand button increases the scrollHeight of the minimized code viewport
|
2022-11-19 18:42:07 -06:00
|
|
|
store-property: (smallOffsetHeight, ".scraped-example-list > .scraped-example pre", "offsetHeight")
|
|
|
|
assert-property-false: (".scraped-example-list > .scraped-example pre", {
|
2023-01-08 14:29:57 -06:00
|
|
|
"scrollHeight": |smallOffsetHeight|
|
2022-11-19 18:42:07 -06:00
|
|
|
})
|
|
|
|
focus: ".scraped-example-list > .scraped-example .expand"
|
|
|
|
press-key: "Enter"
|
|
|
|
assert-property-false: (".scraped-example-list > .scraped-example pre", {
|
2023-01-08 14:29:57 -06:00
|
|
|
"offsetHeight": |smallOffsetHeight|
|
2022-11-19 18:42:07 -06:00
|
|
|
})
|
|
|
|
store-property: (fullOffsetHeight, ".scraped-example-list > .scraped-example pre", "offsetHeight")
|
|
|
|
assert-property: (".scraped-example-list > .scraped-example pre", {
|
2023-01-08 14:29:57 -06:00
|
|
|
"scrollHeight": |fullOffsetHeight|
|
2022-12-05 16:04:57 -06:00
|
|
|
})
|