Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rustdoc: rename issue-\d+.rs tests to have meaningful names (part 3) #116824

Merged
merged 5 commits into from
Oct 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
// check-pass

// Test that associated item impls on primitive types don't crash rustdoc

// https://github.com/rust-lang/rust/issues/31808
#![crate_name="issue_31808"]

pub trait Foo {
const BAR: usize;
type BAZ;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/29503
#![crate_name="issue_29503"]

use std::fmt;

// @has issue_29503/trait.MyTrait.html
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/33302
#![crate_name="issue_33302"]

// Ensure constant and array length values are not taken from source
// code, which wreaks havoc with macros.

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/32890
#![crate_name="issue_32890"]

// @has issue_32890/struct.Foo.html
pub struct Foo<T>(T);

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/29449
#![crate_name="issue_29449"]

// @has issue_29449/struct.Foo.html
pub struct Foo;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/33069
#![crate_name="issue_33069"]

pub trait Bar {}

#[doc(hidden)]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
// compile-flags:--test --cfg feature="bar"

// https://github.com/rust-lang/rust/issues/30252
#![crate_name="issue_30252"]

/// ```rust
/// assert_eq!(cfg!(feature = "bar"), true);
/// ```
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/32556
#![crate_name="issue_32556"]

/// Blah blah blah
/// ```ignore (testing rustdoc's handling of ignore)
/// bad_assert!();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// https://github.com/rust-lang/rust/issues/34025
#![crate_name = "foo"]

// @!has 'foo/sys/index.html'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// https://github.com/rust-lang/rust/issues/33592
#![crate_name = "foo"]

pub trait Foo<T> {}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
// aux-build:issue-29584.rs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/29584
#![crate_name="issue_29584"]

extern crate issue_29584;

// @has issue_29584/struct.Foo.html
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
// build-aux-docs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/33178
#![crate_name="issue_33178"]

// @has issue_33178/index.html
// @has - '//a[@title="mod empty"][@href="../empty/index.html"]' empty
pub extern crate empty;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
// aux-build:issue-30109-1.rs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/30109
#![crate_name="issue_30109"]

pub mod quux {
extern crate issue_30109_1 as bar;
use self::bar::Bar;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
// aux-build:variant-struct.rs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/33178
#![crate_name="issue_33178_1"]

// @has issue_33178_1/index.html
// @!has - //a/@title empty
pub extern crate empty;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
// build-aux-docs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/32395
#![crate_name="issue_32395"]

// @has variant_struct/enum.Foo.html
// @!hasraw - 'pub qux'
// @!hasraw - 'pub(crate) qux'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// build-aux-docs
// ignore-cross-compile

// https://github.com/rust-lang/rust/issues/34274
#![crate_name = "foo"]

extern crate issue_34274;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// https://github.com/rust-lang/rust/issues/32374
#![feature(staged_api)]
#![doc(issue_tracker_base_url = "https://issue_url/")]
#![unstable(feature = "test", issue = "32374")]
#![crate_name="issue_32374"]

// @matches issue_32374/index.html '//*[@class="item-name"]/span[@class="stab deprecated"]' \
// 'Deprecated'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
// https://github.com/rust-lang/rust/issues/31899
#![crate_name="issue_31899"]

// @has issue_31899/index.html
// @hasraw - 'Make this line a bit longer.'
// @!hasraw - 'rust rust-example-rendered'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
// @has issue_30366/index.html '//a/@href' 'http://www.rust-lang.org/'

// https://github.com/rust-lang/rust/issues/30366
#![crate_name="issue_30366"]

/// Describe it. [Link somewhere][1].
///
/// [1]: http://www.rust-lang.org/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// Regression test for <https://github.com/rust-lang/rust/issues/32077>.

// https://github.com/rust-lang/rust/issues/32077
#![crate_name = "foo"]

pub struct GenericStruct<T>(T);
Expand Down