mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
Fix race condition in panic_abort_tests
This commit is contained in:
parent
fcb79a5c45
commit
be6598b7f0
@ -5009,7 +5009,11 @@ fn panic_abort_tests() {
|
||||
.file("a/src/lib.rs", "pub fn foo() {}")
|
||||
.build();
|
||||
|
||||
p.cargo("test -Z panic-abort-tests -v")
|
||||
// This uses -j1 because of a race condition. Otherwise it will build the
|
||||
// two copies of `foo` in parallel, and which one is first is random. If
|
||||
// `--test` is first, then the first line with `[..]` will match, and the
|
||||
// second line with `--test` will fail.
|
||||
p.cargo("test -Z panic-abort-tests -v -j1")
|
||||
.with_stderr_data(
|
||||
str![[r#"
|
||||
[RUNNING] `[..]--crate-name a [..]-C panic=abort[..]`
|
||||
|
Loading…
x
Reference in New Issue
Block a user