-
Notifications
You must be signed in to change notification settings - Fork 386
Add ./miri run-dep
for running a file with test dependencies available
#2890
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
config.program.args.push("--color".into()); | ||
config.program.args.push("always".into()); | ||
let mut cmd = ui_test::test_command(config, Path::new(&path))?; | ||
cmd.arg("--"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Who is this --
for? Separating cargo run
arguments from arguments passed to the program?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, i'll add a comment
tests/compiletest.rs
Outdated
@@ -250,6 +266,19 @@ fn main() -> Result<()> { | |||
Ok(()) | |||
} | |||
|
|||
fn run_dep_mode(target: String, mut args: impl Iterator<Item = OsString>) -> 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); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let mut config = test_config(&target, "", Mode::Yolo, true); | |
let mut config = test_config(&target, "", Mode::Yolo, /* with_dependencies */ true); |
r=me with comments resolving the last 2 nits |
@bors r=RalfJung |
☀️ Test successful - checks-actions |
fixes #2443