pub struct Commander { /* private fields */ }Expand description
Commander allows you to start localnet, build programs,
run tests and do other useful operations.
Implementations§
Source§impl Commander
impl Commander
pub async fn run( &self, target: String, with_exit_code: bool, seed: Option<String>, ) -> Result<(), Error>
pub async fn run_default( &self, target: &str, seed: Option<String>, with_exit_code: bool, ) -> Result<(), Error>
pub async fn run_with_coverage( &self, target: &str, config: &TridentConfig, coverage_config: CoverageConfig, seed: Option<String>, with_exit_code: bool, ) -> Result<(), Error>
pub async fn run_debug(&self, target: String, seed: String) -> Result<(), Error>
Source§impl Commander
impl Commander
pub fn new(root: &str) -> Self
pub async fn build_anchor_project( root: &Path, program_name: Option<String>, ) -> Result<(), Error>
Sourcepub async fn format_program_code_nightly(code: &str) -> Result<String, Error>
pub async fn format_program_code_nightly(code: &str) -> Result<String, Error>
Formats program code - nightly.
pub async fn clean_target(&self) -> Result<(), Error>
pub fn get_target_dir(&self) -> Result<String, Error>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Commander
impl RefUnwindSafe for Commander
impl Send for Commander
impl Sync for Commander
impl Unpin for Commander
impl UnwindSafe for Commander
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more