We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4f39abd commit e0f3374Copy full SHA for e0f3374
1 file changed
crates/snapbox/src/cmd.rs
@@ -17,6 +17,20 @@ pub struct Command {
17
18
/// # Builder API
19
impl Command {
20
+ /// Look up the path to a cargo-built binary within an integration test
21
+ ///
22
+ /// Cargo support:
23
+ /// - `>1.94`: works
24
+ /// - `>=1.91,<=1.93`: works with default `build-dir`
25
+ /// - `<=1.92`: works
26
27
+ /// # Panic
28
29
+ /// Panics if no binary is found
30
+ pub fn cargo_bin(name: &str) -> Self {
31
+ Self::new(cargo_bin(name))
32
+ }
33
+
34
pub fn new(program: impl AsRef<std::ffi::OsStr>) -> Self {
35
Self {
36
cmd: std::process::Command::new(program),
0 commit comments