Struct tendermint_testgen::command::Command
source · [−]pub struct Command { /* private fields */ }
Expand description
A thin wrapper around process::Command to facilitate running external commands.
Implementations
sourceimpl Command
impl Command
sourcepub fn exists_program(program: &str) -> bool
pub fn exists_program(program: &str) -> bool
Check whether the given program can be executed
sourcepub fn arg_from_parts(&mut self, parts: Vec<&str>) -> &mut Self
pub fn arg_from_parts(&mut self, parts: Vec<&str>) -> &mut Self
Add a new program argument, concatenated from several parts
sourcepub fn current_dir(&mut self, dir: &str) -> &mut Self
pub fn current_dir(&mut self, dir: &str) -> &mut Self
Set the working directory for the child process
sourcepub fn spawn(&mut self) -> Result<CommandRun>
pub fn spawn(&mut self) -> Result<CommandRun>
Execute the command as a child process, and extract its status, stdout, stderr.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Command
impl Send for Command
impl Sync for Command
impl Unpin for Command
impl UnwindSafe for Command
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more