Skip to content
/ rust Public
forked from rust-lang/rust

Commit 1a5ebc9

Browse files
authored
Rollup merge of rust-lang#136258 - notriddle:notriddle/issue-d, r=fmease
rustdoc: rename `issue-\d+.rs` tests to have meaningful names (part 11) Follow up * rust-lang#134053 * rust-lang#130287 et al As always, it's easier to review the commits one at a time. Don't use the Files Changed tab. It's confusing.
2 parents 7f05c7e + c17d568 commit 1a5ebc9

20 files changed

+79
-32
lines changed

tests/rustdoc/intra-doc/issue-104145.rs renamed to tests/rustdoc-ui/intra-doc/ice-extern-trait-local-impl-104145.rs

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/issues/104145
2+
//@ check-pass
3+
14
// Doc links in `Trait`'s methods are resolved because it has a local impl.
25

36
//@ aux-build:issue-103463-aux.rs

tests/rustdoc/intra-doc/issue-103463.rs renamed to tests/rustdoc-ui/intra-doc/ice-priv-use-103463.rs

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/issues/103463
2+
//@ check-pass
3+
14
// The `Trait` is not pulled into the crate resulting in doc links in its methods being resolved.
25

36
//@ aux-build:issue-103463-aux.rs

tests/rustdoc/inline_cross/issue-28480.rs renamed to tests/rustdoc/inline_cross/doc-hidden-broken-link-28480.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/issues/28480
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:rustdoc-hidden-sig.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
@@ -7,7 +10,7 @@
710
//@ has - '//a' 'u8'
811
extern crate rustdoc_hidden_sig;
912

10-
//@ has issue_28480/struct.Bar.html
13+
//@ has foobar/struct.Bar.html
1114
//@ !has - '//a/@title' 'Hidden'
1215
//@ has - '//a' 'u8'
1316
pub use rustdoc_hidden_sig::Bar;
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,30 @@
1+
// https://github.com/rust-lang/rust/issues/31948
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:rustdoc-nonreachable-impls.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
47

58
extern crate rustdoc_nonreachable_impls;
69

7-
//@ has issue_31948_1/struct.Wobble.html
10+
//@ has foobar/struct.Wobble.html
811
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bark for'
912
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Woof for'
1013
//@ !has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bar for'
1114
//@ !has - '//*[@class="impl"]//h3[@class="code-header"]' 'Qux for'
1215
pub use rustdoc_nonreachable_impls::hidden::Wobble;
1316

14-
//@ has issue_31948_1/trait.Bark.html
17+
//@ has foobar/trait.Bark.html
1518
//@ has - '//h3[@class="code-header"]' 'for Foo'
1619
//@ has - '//h3[@class="code-header"]' 'for Wobble'
1720
//@ !has - '//h3[@class="code-header"]' 'for Wibble'
1821
pub use rustdoc_nonreachable_impls::Bark;
1922

20-
//@ has issue_31948_1/trait.Woof.html
23+
//@ has foobar/trait.Woof.html
2124
//@ has - '//h3[@class="code-header"]' 'for Foo'
2225
//@ has - '//h3[@class="code-header"]' 'for Wobble'
2326
//@ !has - '//h3[@class="code-header"]' 'for Wibble'
2427
pub use rustdoc_nonreachable_impls::Woof;
2528

26-
//@ !has issue_31948_1/trait.Bar.html
27-
//@ !has issue_31948_1/trait.Qux.html
29+
//@ !has foobar/trait.Bar.html
30+
//@ !has foobar/trait.Qux.html
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,24 @@
1+
// https://github.com/rust-lang/rust/issues/31948
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:rustdoc-nonreachable-impls.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
47

58
extern crate rustdoc_nonreachable_impls;
69

7-
//@ has issue_31948_2/struct.Wobble.html
10+
//@ has foobar/struct.Wobble.html
811
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Qux for'
912
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bark for'
1013
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Woof for'
1114
//@ !has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bar for'
1215
pub use rustdoc_nonreachable_impls::hidden::Wobble;
1316

14-
//@ has issue_31948_2/trait.Qux.html
17+
//@ has foobar/trait.Qux.html
1518
//@ has - '//h3[@class="code-header"]' 'for Foo'
1619
//@ has - '//h3[@class="code-header"]' 'for Wobble'
1720
pub use rustdoc_nonreachable_impls::hidden::Qux;
1821

19-
//@ !has issue_31948_2/trait.Bar.html
20-
//@ !has issue_31948_2/trait.Woof.html
21-
//@ !has issue_31948_2/trait.Bark.html
22+
//@ !has foobar/trait.Bar.html
23+
//@ !has foobar/trait.Woof.html
24+
//@ !has foobar/trait.Bark.html
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,32 @@
1+
// https://github.com/rust-lang/rust/issues/31948
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:rustdoc-nonreachable-impls.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
47

58
extern crate rustdoc_nonreachable_impls;
69

7-
//@ has issue_31948/struct.Foo.html
10+
//@ has foobar/struct.Foo.html
811
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bark for'
912
//@ has - '//*[@class="impl"]//h3[@class="code-header"]' 'Woof for'
1013
//@ !has - '//*[@class="impl"]//h3[@class="code-header"]' 'Bar for'
1114
//@ !has - '//*[@class="impl"]//h3[@class="code-header"]' 'Qux for'
1215
pub use rustdoc_nonreachable_impls::Foo;
1316

14-
//@ has issue_31948/trait.Bark.html
17+
//@ has foobar/trait.Bark.html
1518
//@ has - '//h3[@class="code-header"]' 'for Foo'
1619
//@ !has - '//h3[@class="code-header"]' 'for Wibble'
1720
//@ !has - '//h3[@class="code-header"]' 'for Wobble'
1821
pub use rustdoc_nonreachable_impls::Bark;
1922

20-
//@ has issue_31948/trait.Woof.html
23+
//@ has foobar/trait.Woof.html
2124
//@ has - '//h3[@class="code-header"]' 'for Foo'
2225
//@ !has - '//h3[@class="code-header"]' 'for Wibble'
2326
//@ !has - '//h3[@class="code-header"]' 'for Wobble'
2427
pub use rustdoc_nonreachable_impls::Woof;
2528

26-
//@ !has issue_31948/trait.Bar.html
27-
//@ !has issue_31948/trait.Qux.html
28-
//@ !has issue_31948/struct.Wibble.html
29-
//@ !has issue_31948/struct.Wobble.html
29+
//@ !has foobar/trait.Bar.html
30+
//@ !has foobar/trait.Qux.html
31+
//@ !has foobar/struct.Wibble.html
32+
//@ !has foobar/struct.Wobble.html

tests/rustdoc/inline_cross/issue-32881.rs renamed to tests/rustdoc/inline_cross/impl-dyn-trait-32881.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1+
// https://github.com/rust-lang/rust/issues/32881
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:rustdoc-trait-object-impl.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
47

58
extern crate rustdoc_trait_object_impl;
69

7-
//@ has issue_32881/trait.Bar.html
10+
//@ has foobar/trait.Bar.html
811
//@ has - '//h3[@class="code-header"]' "impl<'a> dyn Bar"
912
//@ has - '//h3[@class="code-header"]' "impl<'a> Debug for dyn Bar"
1013

Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1+
// https://github.com/rust-lang/rust/issues/33113
2+
#![crate_name="foobar"]
3+
14
//@ aux-build:issue-33113.rs
25
//@ build-aux-docs
36
//@ ignore-cross-compile
47

58
extern crate bar;
69

7-
//@ has issue_33113/trait.Bar.html
10+
//@ has foobar/trait.Bar.html
811
//@ has - '//h3[@class="code-header"]' "for &'a char"
912
//@ has - '//h3[@class="code-header"]' "for Foo"
1013
pub use bar::Bar;

tests/rustdoc/inline_cross/issue-76736-1.rs renamed to tests/rustdoc/inline_cross/rustc-private-76736-1.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// https://github.com/rust-lang/rust/issues/76736
2+
13
//@ aux-build:issue-76736-1.rs
24
//@ aux-build:issue-76736-2.rs
35

tests/rustdoc/inline_cross/issue-76736-2.rs renamed to tests/rustdoc/inline_cross/rustc-private-76736-2.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// https://github.com/rust-lang/rust/issues/76736
2+
13
//@ aux-build:issue-76736-1.rs
24
//@ aux-build:issue-76736-2.rs
35

tests/rustdoc/inline_cross/issue-76736-3.rs renamed to tests/rustdoc/inline_cross/rustc-private-76736-3.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// https://github.com/rust-lang/rust/issues/76736
2+
13
//@ compile-flags: -Zforce-unstable-if-unmarked
24
//@ aux-build:issue-76736-1.rs
35
//@ aux-build:issue-76736-2.rs

tests/rustdoc/inline_cross/issue-76736-4.rs renamed to tests/rustdoc/inline_cross/rustc-private-76736-4.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// https://github.com/rust-lang/rust/issues/76736
2+
13
//@ aux-build:issue-76736-1.rs
24
//@ aux-build:issue-76736-2.rs
35

tests/rustdoc/inline_cross/issue-24183.rs renamed to tests/rustdoc/inline_cross/self-sized-bounds-24183.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// https://github.com/rust-lang/rust/issues/24183
12
#![crate_type = "lib"]
23
#![crate_name = "usr"]
34

Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
1-
//@ !has issue_32343/struct.Foo.html
2-
//@ has issue_32343/index.html
1+
// https://github.com/rust-lang/rust/issues/32343
2+
#![crate_name="foobar"]
3+
4+
//@ !has foobar/struct.Foo.html
5+
//@ has foobar/index.html
36
//@ has - '//code' 'pub use foo::Foo'
47
//@ !has - '//code/a' 'Foo'
58
#[doc(no_inline)]
69
pub use foo::Foo;
710

8-
//@ !has issue_32343/struct.Bar.html
9-
//@ has issue_32343/index.html
11+
//@ !has foobar/struct.Bar.html
12+
//@ has foobar/index.html
1013
//@ has - '//code' 'pub use foo::Bar'
1114
//@ has - '//code/a' 'Bar'
1215
#[doc(no_inline)]
@@ -18,6 +21,6 @@ mod foo {
1821
}
1922

2023
pub mod bar {
21-
//@ has issue_32343/bar/struct.Bar.html
24+
//@ has foobar/bar/struct.Bar.html
2225
pub use ::foo::Bar;
2326
}

tests/rustdoc/inline_local/issue-28537.rs renamed to tests/rustdoc/inline_local/pub-re-export-28537.rs

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/issues/28537
2+
#![crate_name="foo"]
3+
14
#[doc(hidden)]
25
pub mod foo {
36
pub struct Foo;
@@ -10,8 +13,8 @@ mod bar {
1013
}
1114
}
1215

13-
//@ has issue_28537/struct.Foo.html
16+
//@ has foo/struct.Foo.html
1417
pub use foo::Foo;
1518

16-
//@ has issue_28537/struct.Bar.html
19+
//@ has foo/struct.Bar.html
1720
pub use self::bar::Bar;

tests/rustdoc/intra-doc/issue-82209.rs renamed to tests/rustdoc/intra-doc/enum-self-82209.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// https://github.com/rust-lang/rust/issues/82209
2+
13
#![crate_name = "foo"]
24
#![deny(rustdoc::broken_intra_doc_links)]
35
pub enum Foo {

tests/rustdoc/intra-doc/issue-108459.rs renamed to tests/rustdoc/intra-doc/link-same-name-different-disambiguator-108459.rs

+7-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/pull/108459
2+
#![crate_name="foobar"]
3+
14
#![deny(rustdoc::broken_intra_doc_links)]
25
#![allow(rustdoc::redundant_explicit_links)]
36

@@ -13,13 +16,13 @@ pub struct MyStruct1;
1316
// the same target but different text
1417

1518
/// See also [crate::char] and [mod@char] and [prim@char]
16-
//@ has issue_108459/struct.MyStruct2.html '//*[@href="char/index.html"]' 'crate::char'
19+
//@ has foobar/struct.MyStruct2.html '//*[@href="char/index.html"]' 'crate::char'
1720
//@ has - '//*[@href="char/index.html"]' 'char'
1821
//@ has - '//*[@href="{{channel}}/std/primitive.char.html"]' 'char'
1922
pub struct MyStruct2;
2023

2124
/// See also [mod@char] and [prim@char] and [crate::char]
22-
//@ has issue_108459/struct.MyStruct3.html '//*[@href="char/index.html"]' 'crate::char'
25+
//@ has foobar/struct.MyStruct3.html '//*[@href="char/index.html"]' 'crate::char'
2326
//@ has - '//*[@href="char/index.html"]' 'char'
2427
//@ has - '//*[@href="{{channel}}/std/primitive.char.html"]' 'char'
2528
pub struct MyStruct3;
@@ -28,11 +31,11 @@ pub struct MyStruct3;
2831
// different targets
2932

3033
/// See also [char][mod@char] and [char][prim@char]
31-
//@ has issue_108459/struct.MyStruct4.html '//*[@href="char/index.html"]' 'char'
34+
//@ has foobar/struct.MyStruct4.html '//*[@href="char/index.html"]' 'char'
3235
//@ has - '//*[@href="{{channel}}/std/primitive.char.html"]' 'char'
3336
pub struct MyStruct4;
3437

3538
/// See also [char][prim@char] and [char][crate::char]
36-
//@ has issue_108459/struct.MyStruct5.html '//*[@href="char/index.html"]' 'char'
39+
//@ has foobar/struct.MyStruct5.html '//*[@href="char/index.html"]' 'char'
3740
//@ has - '//*[@href="{{channel}}/std/primitive.char.html"]' 'char'
3841
pub struct MyStruct5;
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// https://github.com/rust-lang/rust/issues/66159
2+
#![crate_name="foobar"]
3+
14
//@ aux-crate:priv:pub_struct=pub-struct.rs
25
//@ compile-flags:-Z unstable-options
36

@@ -6,5 +9,5 @@
69
// Since we don't generate the docs for the auxiliary files, we can't actually
710
// verify that the struct is linked correctly.
811

9-
//@ has issue_66159/index.html
12+
//@ has foobar/index.html
1013
//! [pub_struct::SomeStruct]

0 commit comments

Comments
 (0)