Fix error code failure check in rustdoc test
This commit is contained in:
@@ -299,7 +299,6 @@ fn run_test(
|
|||||||
eprint!("{}", self.0);
|
eprint!("{}", self.0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let out = str::from_utf8(&output.stderr).unwrap();
|
let out = str::from_utf8(&output.stderr).unwrap();
|
||||||
let _bomb = Bomb(&out);
|
let _bomb = Bomb(&out);
|
||||||
match (output.status.success(), compile_fail) {
|
match (output.status.success(), compile_fail) {
|
||||||
@@ -309,7 +308,7 @@ fn run_test(
|
|||||||
(true, false) => {}
|
(true, false) => {}
|
||||||
(false, true) => {
|
(false, true) => {
|
||||||
if !error_codes.is_empty() {
|
if !error_codes.is_empty() {
|
||||||
error_codes.retain(|err| !out.contains(err));
|
error_codes.retain(|err| !out.contains(&format!("error[{}]: ", err)));
|
||||||
|
|
||||||
if !error_codes.is_empty() {
|
if !error_codes.is_empty() {
|
||||||
return Err(TestFailure::MissingErrorCodes(error_codes));
|
return Err(TestFailure::MissingErrorCodes(error_codes));
|
||||||
|
|||||||
Reference in New Issue
Block a user