Skip to content

Commit f2c8070

Browse files
committed
Fix rare failure in collision_export test.
1 parent 62180bf commit f2c8070

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/testsuite/collisions.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,8 @@ This may become a hard error in the future; see <https://github.com/rust-lang/ca
9191
}
9292

9393
#[cargo_test]
94+
// --out-dir and examples are currently broken on MSVC.
95+
// See https://github.com/rust-lang/cargo/issues/7493
9496
#[cfg(not(target_env = "msvc"))]
9597
fn collision_export() {
9698
// `--out-dir` combines some things which can cause conflicts.
@@ -100,7 +102,9 @@ fn collision_export() {
100102
.file("src/main.rs", "fn main() {}")
101103
.build();
102104

103-
p.cargo("build --out-dir=out -Z unstable-options --bins --examples")
105+
// -j1 to avoid issues with two processes writing to the same file at the
106+
// same time.
107+
p.cargo("build -j1 --out-dir=out -Z unstable-options --bins --examples")
104108
.masquerade_as_nightly_cargo()
105109
.with_stderr_contains("\
106110
[WARNING] `--out-dir` filename collision.

0 commit comments

Comments
 (0)