From 2f187343b9959f67fd058773fe18ede4e04d1383 Mon Sep 17 00:00:00 2001 From: Oli Scherer Date: Fri, 12 May 2023 14:19:34 +0000 Subject: [PATCH] Document arguments and interesting flags --- src/tools/miri/tests/compiletest.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/tools/miri/tests/compiletest.rs b/src/tools/miri/tests/compiletest.rs index 435771c2f398..fa06c4b6a128 100644 --- a/src/tools/miri/tests/compiletest.rs +++ b/src/tools/miri/tests/compiletest.rs @@ -268,11 +268,13 @@ fn main() -> Result<()> { fn run_dep_mode(target: String, mut args: impl Iterator) -> Result<()> { let path = args.next().expect("./miri run-dep must be followed by a file name"); - let mut config = test_config(&target, "", Mode::Yolo, true); + let mut config = test_config(&target, "", Mode::Yolo, /* with dependencies */ true); config.program.args.remove(0); // remove the `--error-format=json` argument config.program.args.push("--color".into()); config.program.args.push("always".into()); let mut cmd = ui_test::test_command(config, Path::new(&path))?; + // Separate the arguments to the `cargo miri` invocation from + // the arguments to the interpreted prog cmd.arg("--"); cmd.args(args); println!("{cmd:?}");