Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 9248b01

Browse files
committedNov 11, 2019
Auto merge of #66213 - tmiasko:mandatory-error-warn, r=petrochenkov
Make error and warning annotations mandatory in UI tests This change makes error and warning annotations mandatory in UI tests. The only exception are tests that use error patterns to match compiler output and don't have any annotations. Fixes #55596.
2 parents 2a9be46 + 427952e commit 9248b01

File tree

94 files changed

+464
-416
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

94 files changed

+464
-416
lines changed
 
Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,26 @@
11
// ignore-tidy-cr
2-
3-
// build-pass (FIXME(62277): could be check-pass?)
2+
// build-pass
43

54
// This file checks the spans of intra-link warnings in a file with CRLF line endings. The
65
// .gitattributes file in this directory should enforce it.
76

87
/// [error]
98
pub struct A;
9+
//~^^ WARNING `[error]` cannot be resolved
1010

1111
///
1212
/// docs [error1]
13+
//~^ WARNING `[error1]` cannot be resolved
1314

1415
/// docs [error2]
1516
///
1617
pub struct B;
18+
//~^^^ WARNING `[error2]` cannot be resolved
1719

1820
/**
1921
* This is a multi-line comment.
2022
*
2123
* It also has an [error].
2224
*/
2325
pub struct C;
26+
//~^^^ WARNING `[error]` cannot be resolved

‎src/test/rustdoc-ui/intra-links-warning-crlf.stderr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
warning: `[error]` cannot be resolved, ignoring it...
2-
--> $DIR/intra-links-warning-crlf.rs:8:6
2+
--> $DIR/intra-links-warning-crlf.rs:7:6
33
|
44
LL | /// [error]
55
| ^^^^^ cannot be resolved, ignoring
@@ -16,15 +16,15 @@ LL | /// docs [error1]
1616
= help: to escape `[` and `]` characters, just add '\' before them like `\[` or `\]`
1717

1818
warning: `[error2]` cannot be resolved, ignoring it...
19-
--> $DIR/intra-links-warning-crlf.rs:14:11
19+
--> $DIR/intra-links-warning-crlf.rs:15:11
2020
|
2121
LL | /// docs [error2]
2222
| ^^^^^^ cannot be resolved, ignoring
2323
|
2424
= help: to escape `[` and `]` characters, just add '\' before them like `\[` or `\]`
2525

2626
warning: `[error]` cannot be resolved, ignoring it...
27-
--> $DIR/intra-links-warning-crlf.rs:21:20
27+
--> $DIR/intra-links-warning-crlf.rs:23:20
2828
|
2929
LL | * It also has an [error].
3030
| ^^^^^ cannot be resolved, ignoring

0 commit comments

Comments
 (0)
Please sign in to comment.