Closed ilyagr closed 1 year ago
I updated the above; it seems this does cause harm if there are any snapshots to review.
I currently do not have the resources to fix this, but I believe it would be a rather straightforward change. If you print out the command that's being invoked in cargo-insta
you can probably figure out what would need to be changed for nextest.
I might look into it, thanks for the pointer! I'd need to learn a bit more about the interface to cargo test
and cargo-nextest
. If I don't get to it, there's no rush.
The entire logic about how the command line is created is found in this one function: https://github.com/mitsuhiko/insta/blob/8006453e932826a0fc3396d239ba2c3c3cde175a/cargo-insta/src/cli.rs#L739
Fixed in 1ae7bd2bb472d7ba8124a4f200b0f1609348dddf
Thank you very much! Sorry I didn't get to it.
What happened?
Running
cargo insta test --test-runner nextest --test test_resolve_command
works, but leaves a error:The error is on the last line.
Update: It does cause harm: if there are any snapshots that changed, the command does not tell you about it.
Reproduction steps
cargo install cargo-insta cargo-nextest
(I havecargo-nextest 0.9.47
)test_resolve_command.rs
.cargo insta test --test-runner nextest --test test_resolve_command
cargo insta review
. (It does seem to work if executed manually)Insta Version
cargo-insta 1.23.0
rustc Version
rustc 1.67.0-beta.2 (352eb59a4 2022-12-13)
What did you expect?
No error at the end of the output, and a notification to review the changed snapshots.