From 6ce927a0d2982366fb44987ebfe94e399748319f Mon Sep 17 00:00:00 2001 From: bors Date: Fri, 26 Mar 2021 16:59:39 +0000 Subject: [PATCH] Auto merge of #9307 - ijackson:exit-code-string, r=joshtriplett tests: Tolerate "exit status" in error messages "exit code" is wrong terminology on Unix. I am trying to fix this in Rust stdlib in https://github.com/rust-lang/rust/pull/83462 but this currently breaks the cargo test suite. See that MR for full explanation of the change. --- tests/testsuite/build_script.rs | 2 +- tests/testsuite/run.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/testsuite/build_script.rs b/tests/testsuite/build_script.rs index 89b38810aeb..8d9011d53d2 100644 --- a/tests/testsuite/build_script.rs +++ b/tests/testsuite/build_script.rs @@ -38,7 +38,7 @@ fn custom_build_script_failed() { [ERROR] failed to run custom build command for `foo v0.5.0 ([CWD])` Caused by: - process didn't exit successfully: `[..]/build-script-build` (exit code: 101)", + process didn't exit successfully: `[..]/build-script-build` (exit [..]: 101)", ) .run(); } diff --git a/tests/testsuite/run.rs b/tests/testsuite/run.rs index 9d52afaf7b0..1614b2a29c5 100644 --- a/tests/testsuite/run.rs +++ b/tests/testsuite/run.rs @@ -118,7 +118,7 @@ fn exit_code() { ); if !cfg!(unix) { output.push_str( - "[ERROR] process didn't exit successfully: `target[..]foo[..]` (exit code: 2)", + "[ERROR] process didn't exit successfully: `target[..]foo[..]` (exit [..]: 2)", ); } p.cargo("run").with_status(2).with_stderr(output).run(); @@ -140,7 +140,7 @@ fn exit_code_verbose() { ); if !cfg!(unix) { output.push_str( - "[ERROR] process didn't exit successfully: `target[..]foo[..]` (exit code: 2)", + "[ERROR] process didn't exit successfully: `target[..]foo[..]` (exit [..]: 2)", ); }