Update error code detection in compile_fail doctests

This commit is contained in:
Guillaume Gomez 2020-07-14 14:44:12 +02:00
parent 96a6a5fec1
commit 54e8216348

View File

@ -333,7 +333,7 @@ fn run_test(
(true, false) => {}
(false, true) => {
if !error_codes.is_empty() {
error_codes.retain(|err| !out.contains(&format!("error[{}]: ", err)));
error_codes.retain(|err| !out.contains(&format!("error[{}]", err)));
if !error_codes.is_empty() {
return Err(TestFailure::MissingErrorCodes(error_codes));