From 8844261a21bf8513032320d3214adacf3bc23b2e Mon Sep 17 00:00:00 2001 From: Andrei Marinica Date: Fri, 27 Oct 2023 09:35:33 +0300 Subject: [PATCH] cargo fmt --- framework/meta/src/cli_args/cli_args_standalone.rs | 5 +---- framework/meta/src/cmd/standalone.rs | 8 +++----- framework/meta/src/cmd/standalone/test.rs | 3 +-- 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/framework/meta/src/cli_args/cli_args_standalone.rs b/framework/meta/src/cli_args/cli_args_standalone.rs index dce4f218de..dab29f2119 100644 --- a/framework/meta/src/cli_args/cli_args_standalone.rs +++ b/framework/meta/src/cli_args/cli_args_standalone.rs @@ -4,7 +4,6 @@ use clap::{ArgAction, Args, Parser, Subcommand}; use super::{CliArgsToRaw, ContractCliAction}; - /// Parsed arguments of the meta crate CLI. #[derive(Default, PartialEq, Eq, Debug, Parser)] #[command( @@ -79,8 +78,6 @@ pub struct InfoArgs { pub ignore: Vec, } - - #[derive(Default, Clone, PartialEq, Eq, Debug, Args)] pub struct TestArgs { /// Target directory where to generate contract integration tests. @@ -97,7 +94,7 @@ pub struct TestArgs { /// Default value will be "false" if not specified. /// If scen and go are both specified, scen overrides the go argument. #[arg(short, long, default_value = "false", verbatim_doc_comment)] - pub scen: bool + pub scen: bool, } #[derive(Default, Clone, PartialEq, Eq, Debug, Args)] diff --git a/framework/meta/src/cmd/standalone.rs b/framework/meta/src/cmd/standalone.rs index 595c5d5050..9ee57986ce 100644 --- a/framework/meta/src/cmd/standalone.rs +++ b/framework/meta/src/cmd/standalone.rs @@ -2,8 +2,8 @@ mod all; mod info; mod local_deps; pub mod scen_test_gen; -pub(crate) mod upgrade; pub mod test; +pub(crate) mod upgrade; use crate::{ cli_args::{StandaloneCliAction, StandaloneCliArgs}, @@ -14,8 +14,8 @@ use clap::Parser; use info::call_info; use local_deps::local_deps; use scen_test_gen::test_gen_tool; -use upgrade::upgrade_sc; use test::test; +use upgrade::upgrade_sc; /// Entry point in the program when calling it as a standalone tool. pub async fn cli_main_standalone() { @@ -38,9 +38,7 @@ pub async fn cli_main_standalone() { Some(StandaloneCliAction::TestGen(args)) => { test_gen_tool(args); }, - Some(StandaloneCliAction::Test(args)) => { - test(args) - } + Some(StandaloneCliAction::Test(args)) => test(args), None => {}, } } diff --git a/framework/meta/src/cmd/standalone/test.rs b/framework/meta/src/cmd/standalone/test.rs index 3225d72765..a66f46c391 100644 --- a/framework/meta/src/cmd/standalone/test.rs +++ b/framework/meta/src/cmd/standalone/test.rs @@ -40,8 +40,7 @@ pub fn test(test_args: &TestArgs) { .unwrap_or_else(|_| { panic!( "{}", - format!("Failed to run program: {program} {args_str}") - .bright_red() + format!("Failed to run program: {program} {args_str}").bright_red() ) });