Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
5e1cbfa
remove const-fn-feature-flags test
sasurau4 Nov 26, 2020
d4ee2f6
Move const ip in ui test to unit test
sasurau4 Nov 26, 2020
f17e648
lint-docs: Move free functions into methods of LintExtractor.
ehuss Nov 28, 2020
d2d91b4
lint-docs: Add --validate flag to validate lint docs separately.
ehuss Nov 28, 2020
ddfb581
Move `src/test/rustdoc` intra-doc link tests into a subdirectory
jyn514 Nov 29, 2020
872acb0
Move `src/test/rustdoc-ui` intra-doc tests into a subdirectory
jyn514 Nov 29, 2020
228510b
lint-docs: Add some extra detail to the error message.
ehuss Nov 28, 2020
a90fdfc
lint-docs: Use strip-prefix to simplify.
ehuss Nov 29, 2020
95a6427
Add -Z normalize-docs and enable it for compiler docs
jyn514 Nov 29, 2020
be554c4
Make ui test that are run-pass and do not test the compiler itself li…
CDirkx Nov 22, 2020
ccbb0f5
Add support for stable-const-since in docs on items (standalone or as…
CraftSpider Nov 30, 2020
4eb64c8
update Miri
RalfJung Nov 30, 2020
1c367c0
Update with status for various NetBSD ports.
he32 Nov 30, 2020
36e6aa0
Stop adding '*' at the end of type names for Ref and Slice when compu…
nanguye Nov 18, 2020
9ba8d6e
Update books
ehuss Dec 1, 2020
b565fe2
Rollup merge of #79038 - CDirkx:move-ui-tests, r=dtolnay
m-ou-se Dec 1, 2020
08b1717
Rollup merge of #79184 - nanguye2496:nanguye2496/fix_slice_and_str_ty…
m-ou-se Dec 1, 2020
bf3f4c8
Rollup merge of #79227 - sasurau4:test/move-cell-test-to-lib-core, r=…
m-ou-se Dec 1, 2020
2404409
Rollup merge of #79444 - sasurau4:test/move-const-ip, r=matklad
m-ou-se Dec 1, 2020
36ce8db
Rollup merge of #79522 - ehuss:lint-check-validate, r=Mark-Simulacrum
m-ou-se Dec 1, 2020
99e075f
Rollup merge of #79525 - jyn514:feature-gate-normalize, r=GuillaumeGomez
m-ou-se Dec 1, 2020
f45e695
Rollup merge of #79527 - jyn514:intra-doc-tests, r=Manishearth
m-ou-se Dec 1, 2020
33d7b8c
Rollup merge of #79548 - CraftSpider:76998, r=jyn514
m-ou-se Dec 1, 2020
1bc1a18
Rollup merge of #79568 - RalfJung:miri, r=RalfJung
m-ou-se Dec 1, 2020
2891f3f
Rollup merge of #79573 - he32:master, r=jonas-schievink
m-ou-se Dec 1, 2020
c06a00e
Rollup merge of #79583 - ehuss:update-books, r=ehuss
m-ou-se Dec 1, 2020
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
Prev Previous commit
Next Next commit
Move src/test/rustdoc-ui intra-doc tests into a subdirectory
This also changes the builder to allow using
`x.py test src/test/rustdoc-ui/intra-doc`; before, it would panic that
no paths were found.
  • Loading branch information
jyn514 committed Nov 29, 2020
commit 872acb0c3589450a10f6fec97cd1a781e2d17794
33 changes: 1 addition & 32 deletions src/bootstrap/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -688,38 +688,6 @@ impl Step for RustdocJSNotStd {
}
}

#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
pub struct RustdocUi {
pub target: TargetSelection,
pub compiler: Compiler,
}

impl Step for RustdocUi {
type Output = ();
const DEFAULT: bool = true;
const ONLY_HOSTS: bool = true;

fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_> {
run.path("src/test/rustdoc-ui")
}

fn make_run(run: RunConfig<'_>) {
let compiler = run.builder.compiler(run.builder.top_stage, run.build_triple());
run.builder.ensure(RustdocUi { target: run.target, compiler });
}

fn run(self, builder: &Builder<'_>) {
builder.ensure(Compiletest {
compiler: self.compiler,
target: self.target,
mode: "ui",
suite: "rustdoc-ui",
path: "src/test/rustdoc-ui",
compare_mode: None,
})
}
}

#[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)]
pub struct Tidy;

Expand Down Expand Up @@ -934,6 +902,7 @@ default_test!(Debuginfo { path: "src/test/debuginfo", mode: "debuginfo", suite:
host_test!(UiFullDeps { path: "src/test/ui-fulldeps", mode: "ui", suite: "ui-fulldeps" });

host_test!(Rustdoc { path: "src/test/rustdoc", mode: "rustdoc", suite: "rustdoc" });
host_test!(RustdocUi { path: "src/test/rustdoc-ui", mode: "ui", suite: "rustdoc-ui" });

host_test!(Pretty { path: "src/test/pretty", mode: "pretty", suite: "pretty" });

Expand Down
1 change: 0 additions & 1 deletion src/test/rustdoc-ui/.gitattributes

This file was deleted.

1 change: 1 addition & 0 deletions src/test/rustdoc-ui/intra-doc/.gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
warning-crlf.rs eol=crlf
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
error: unresolved link to `TypeAlias::hoge`
--> $DIR/intra-doc-alias-ice.rs:5:30
--> $DIR/alias-ice.rs:5:30
|
LL | /// [broken cross-reference](TypeAlias::hoge)
| ^^^^^^^^^^^^^^^ the type alias `TypeAlias` has no associated item named `hoge`
|
note: the lint level is defined here
--> $DIR/intra-doc-alias-ice.rs:1:9
--> $DIR/alias-ice.rs:1:9
|
LL | #![deny(broken_intra_doc_links)]
| ^^^^^^^^^^^^^^^^^^^^^^
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
error: `true` is both a module and a builtin type
--> $DIR/intra-links-ambiguity.rs:38:6
--> $DIR/ambiguity.rs:38:6
|
LL | /// [true]
| ^^^^ ambiguous link
|
note: the lint level is defined here
--> $DIR/intra-links-ambiguity.rs:1:9
--> $DIR/ambiguity.rs:1:9
|
LL | #![deny(broken_intra_doc_links)]
| ^^^^^^^^^^^^^^^^^^^^^^
Expand All @@ -19,7 +19,7 @@ LL | /// [prim@true]
| ^^^^^^^^^

error: `ambiguous` is both a struct and a function
--> $DIR/intra-links-ambiguity.rs:27:6
--> $DIR/ambiguity.rs:27:6
|
LL | /// [`ambiguous`] is ambiguous.
| ^^^^^^^^^^^ ambiguous link
Expand All @@ -34,7 +34,7 @@ LL | /// [`ambiguous()`] is ambiguous.
| ^^^^^^^^^^^^^

error: `ambiguous` is both a struct and a function
--> $DIR/intra-links-ambiguity.rs:29:6
--> $DIR/ambiguity.rs:29:6
|
LL | /// [ambiguous] is ambiguous.
| ^^^^^^^^^ ambiguous link
Expand All @@ -49,7 +49,7 @@ LL | /// [ambiguous()] is ambiguous.
| ^^^^^^^^^^^

error: `multi_conflict` is a struct, a function, and a macro
--> $DIR/intra-links-ambiguity.rs:31:6
--> $DIR/ambiguity.rs:31:6
|
LL | /// [`multi_conflict`] is a three-way conflict.
| ^^^^^^^^^^^^^^^^ ambiguous link
Expand All @@ -68,7 +68,7 @@ LL | /// [`multi_conflict!`] is a three-way conflict.
| ^^^^^^^^^^^^^^^^^

error: `type_and_value` is both a module and a constant
--> $DIR/intra-links-ambiguity.rs:33:16
--> $DIR/ambiguity.rs:33:16
|
LL | /// Ambiguous [type_and_value].
| ^^^^^^^^^^^^^^ ambiguous link
Expand All @@ -83,7 +83,7 @@ LL | /// Ambiguous [const@type_and_value].
| ^^^^^^^^^^^^^^^^^^^^

error: `foo::bar` is both an enum and a function
--> $DIR/intra-links-ambiguity.rs:35:42
--> $DIR/ambiguity.rs:35:42
|
LL | /// Ambiguous non-implied shortcut link [`foo::bar`].
| ^^^^^^^^^^ ambiguous link
Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
error: `Foo::f#hola` contains an anchor, but links to fields are already anchored
--> $DIR/intra-links-anchors.rs:25:15
--> $DIR/anchors.rs:25:15
|
LL | /// Or maybe [Foo::f#hola].
| ^^^^^^^^^^^ contains invalid anchor
|
note: the lint level is defined here
--> $DIR/intra-links-anchors.rs:1:9
--> $DIR/anchors.rs:1:9
|
LL | #![deny(broken_intra_doc_links)]
| ^^^^^^^^^^^^^^^^^^^^^^

error: `hello#people#!` contains multiple anchors
--> $DIR/intra-links-anchors.rs:31:28
--> $DIR/anchors.rs:31:28
|
LL | /// Another anchor error: [hello#people#!].
| ^^^^^^^^^^^^^^ contains invalid anchor

error: `Enum::A#whatever` contains an anchor, but links to variants are already anchored
--> $DIR/intra-links-anchors.rs:37:28
--> $DIR/anchors.rs:37:28
|
LL | /// Damn enum's variants: [Enum::A#whatever].
| ^^^^^^^^^^^^^^^^ contains invalid anchor

error: `u32#hello` contains an anchor, but links to builtin types are already anchored
--> $DIR/intra-links-anchors.rs:43:6
--> $DIR/anchors.rs:43:6
|
LL | /// [u32#hello]
| ^^^^^^^^^ contains invalid anchor
Expand Down
Original file line number Diff line number Diff line change
@@ -1,90 +1,90 @@
error: incompatible link kind for `S`
--> $DIR/intra-links-disambiguator-mismatch.rs:14:14
--> $DIR/disambiguator-mismatch.rs:14:14
|
LL | /// Link to [struct@S]
| ^^^^^^^^ help: to link to the enum, prefix with `enum@`: `enum@S`
|
note: the lint level is defined here
--> $DIR/intra-links-disambiguator-mismatch.rs:1:9
--> $DIR/disambiguator-mismatch.rs:1:9
|
LL | #![deny(broken_intra_doc_links)]
| ^^^^^^^^^^^^^^^^^^^^^^
= note: this link resolved to an enum, which is not a struct

error: incompatible link kind for `S`
--> $DIR/intra-links-disambiguator-mismatch.rs:19:14
--> $DIR/disambiguator-mismatch.rs:19:14
|
LL | /// Link to [mod@S]
| ^^^^^ help: to link to the enum, prefix with `enum@`: `enum@S`
|
= note: this link resolved to an enum, which is not a module

error: incompatible link kind for `S`
--> $DIR/intra-links-disambiguator-mismatch.rs:24:14
--> $DIR/disambiguator-mismatch.rs:24:14
|
LL | /// Link to [union@S]
| ^^^^^^^ help: to link to the enum, prefix with `enum@`: `enum@S`
|
= note: this link resolved to an enum, which is not a union

error: incompatible link kind for `S`
--> $DIR/intra-links-disambiguator-mismatch.rs:29:14
--> $DIR/disambiguator-mismatch.rs:29:14
|
LL | /// Link to [trait@S]
| ^^^^^^^ help: to link to the enum, prefix with `enum@`: `enum@S`
|
= note: this link resolved to an enum, which is not a trait

error: incompatible link kind for `T`
--> $DIR/intra-links-disambiguator-mismatch.rs:34:14
--> $DIR/disambiguator-mismatch.rs:34:14
|
LL | /// Link to [struct@T]
| ^^^^^^^^ help: to link to the trait, prefix with `trait@`: `trait@T`
|
= note: this link resolved to a trait, which is not a struct

error: incompatible link kind for `m`
--> $DIR/intra-links-disambiguator-mismatch.rs:39:14
--> $DIR/disambiguator-mismatch.rs:39:14
|
LL | /// Link to [derive@m]
| ^^^^^^^^ help: to link to the macro, add an exclamation mark: `m!`
|
= note: this link resolved to a macro, which is not a derive macro

error: incompatible link kind for `s`
--> $DIR/intra-links-disambiguator-mismatch.rs:44:14
--> $DIR/disambiguator-mismatch.rs:44:14
|
LL | /// Link to [const@s]
| ^^^^^^^ help: to link to the static, prefix with `static@`: `static@s`
|
= note: this link resolved to a static, which is not a constant

error: incompatible link kind for `c`
--> $DIR/intra-links-disambiguator-mismatch.rs:49:14
--> $DIR/disambiguator-mismatch.rs:49:14
|
LL | /// Link to [static@c]
| ^^^^^^^^ help: to link to the constant, prefix with `const@`: `const@c`
|
= note: this link resolved to a constant, which is not a static

error: incompatible link kind for `c`
--> $DIR/intra-links-disambiguator-mismatch.rs:54:14
--> $DIR/disambiguator-mismatch.rs:54:14
|
LL | /// Link to [fn@c]
| ^^^^ help: to link to the constant, prefix with `const@`: `const@c`
|
= note: this link resolved to a constant, which is not a function

error: incompatible link kind for `c`
--> $DIR/intra-links-disambiguator-mismatch.rs:59:14
--> $DIR/disambiguator-mismatch.rs:59:14
|
LL | /// Link to [c()]
| ^^^ help: to link to the constant, prefix with `const@`: `const@c`
|
= note: this link resolved to a constant, which is not a function

error: incompatible link kind for `f`
--> $DIR/intra-links-disambiguator-mismatch.rs:64:14
--> $DIR/disambiguator-mismatch.rs:64:14
|
LL | /// Link to [const@f]
| ^^^^^^^ help: to link to the function, add parentheses: `f()`
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
warning: `with#anchor#error` contains multiple anchors
--> $DIR/intra-link-double-anchor.rs:5:18
--> $DIR/double-anchor.rs:5:18
|
LL | /// docs [label][with#anchor#error]
| ^^^^^^^^^^^^^^^^^ contains invalid anchor
Expand Down
Loading