1
+ // https://github.com/rust-lang/rust/issues/55364
2
+ #![ crate_name="foo" ]
3
+
1
4
// First a module with inner documentation
2
5
3
- // @has issue_55364 /subone/index.html
6
+ // @has foo /subone/index.html
4
7
// These foo/bar links in the module's documentation should refer inside `subone`
5
8
// @has - '//section[@id="main-content"]/details[@open=""]/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
6
9
// @has - '//section[@id="main-content"]/details[@open=""]/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
7
10
pub mod subone {
8
11
//! See either [foo] or [bar].
9
12
10
13
// This should refer to subone's `bar`
11
- // @has issue_55364 /subone/fn.foo.html
14
+ // @has foo /subone/fn.foo.html
12
15
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
13
16
/// See [bar]
14
17
pub fn foo ( ) { }
15
18
// This should refer to subone's `foo`
16
- // @has issue_55364 /subone/fn.bar.html
19
+ // @has foo /subone/fn.bar.html
17
20
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
18
21
/// See [foo]
19
22
pub fn bar ( ) { }
20
23
}
21
24
22
25
// A module with outer documentation
23
26
24
- // @has issue_55364 /subtwo/index.html
27
+ // @has foo /subtwo/index.html
25
28
// These foo/bar links in the module's documentation should not reference inside `subtwo`
26
29
// @!has - '//section[@id="main-content"]/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
27
30
// @!has - '//section[@id="main-content"]/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
@@ -36,13 +39,13 @@ pub mod subtwo {
36
39
37
40
// Despite the module's docs referring to the top level foo/bar,
38
41
// this should refer to subtwo's `bar`
39
- // @has issue_55364 /subtwo/fn.foo.html
42
+ // @has foo /subtwo/fn.foo.html
40
43
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.bar.html"]' 'bar'
41
44
/// See [bar]
42
45
pub fn foo ( ) { }
43
46
// Despite the module's docs referring to the top level foo/bar,
44
47
// this should refer to subtwo's `foo`
45
- // @has issue_55364 /subtwo/fn.bar.html
48
+ // @has foo /subtwo/fn.bar.html
46
49
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="fn.foo.html"]' 'foo'
47
50
/// See [foo]
48
51
pub fn bar ( ) { }
@@ -57,7 +60,7 @@ pub fn bar() {}
57
60
58
61
// This module refers to the outer foo/bar by means of `super::`
59
62
60
- // @has issue_55364 /subthree/index.html
63
+ // @has foo /subthree/index.html
61
64
// This module should also refer to the top level foo/bar
62
65
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.foo.html"]' 'foo'
63
66
// @has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.bar.html"]' 'bar'
@@ -67,7 +70,7 @@ pub mod subthree {
67
70
68
71
// Next we go *deeper* - In order to ensure it's not just "this or parent"
69
72
// we test `crate::` and a `super::super::...` chain
70
- // @has issue_55364 /subfour/subfive/subsix/subseven/subeight/index.html
73
+ // @has foo /subfour/subfive/subsix/subseven/subeight/index.html
71
74
// @has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subone/fn.foo.html"]' 'other foo'
72
75
// @has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subtwo/fn.bar.html"]' 'other bar'
73
76
pub mod subfour {
0 commit comments