Skip to content

Commit 02ea750

Browse files
committed
add compiletest headers to rustdoc-gui tests
1 parent 6a34732 commit 02ea750

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

tests/rustdoc-gui/source-anchor-scroll.goml

+4-4
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ set-window-size: (600, 800)
88
assert-property: ("html", {"scrollTop": "0"})
99

1010
click: '//a[text() = "barbar"]'
11-
assert-property: ("html", {"scrollTop": "125"})
11+
assert-property: ("html", {"scrollTop": "149"})
1212
click: '//a[text() = "bar"]'
13-
assert-property: ("html", {"scrollTop": "156"})
13+
assert-property: ("html", {"scrollTop": "180"})
1414
click: '//a[text() = "sub_fn"]'
15-
assert-property: ("html", {"scrollTop": "53"})
15+
assert-property: ("html", {"scrollTop": "77"})
1616

1717
// We now check that clicking on lines doesn't change the scroll
1818
// Extra information: the "sub_fn" function header is on line 1.
1919
click: '//*[@id="6"]'
20-
assert-property: ("html", {"scrollTop": "53"})
20+
assert-property: ("html", {"scrollTop": "77"})
+1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
// compile-flags: --extend-css extra.css
12
//! <div class="extend">text in red</div>

tests/rustdoc-gui/src/link_to_definition/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// compile-flags: -Zunstable-options --generate-link-to-definition
12
pub fn sub_fn() {
23
barbar();
34
}

tests/rustdoc-gui/src/scrape_examples/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// run-flags:-Zrustdoc-scrape-examples
12
/// # Examples
23
///
34
/// ```

0 commit comments

Comments
 (0)