diff --git a/src/cmd/new.rs b/src/cmd/new.rs index 187e1c34589435fad088239aad6ecd84116a3ddf..7fefd21b03f5e6ff675e0dd79182d1286283bd78 100644 --- a/src/cmd/new.rs +++ b/src/cmd/new.rs @@ -99,12 +99,12 @@ where #[cfg(test)] mod tests { use super::*; - use crate::{cmd, util::tests::with_tmp_dir}; + use crate::util::tests::with_tmp_dir; #[test] fn rejects_hyphenated_name() { with_tmp_dir(|path| { - let result = cmd::new::execute("rejects-hyphenated-name", Some(path)); + let result = execute("rejects-hyphenated-name", Some(path)); assert!(result.is_err(), "Should fail"); assert_eq!( result.err().unwrap().to_string(), @@ -119,7 +119,7 @@ mod tests { with_tmp_dir(|path| { let name = "test_contract_cargo_project_already_exists"; let _ = execute(name, Some(path)); - let result = cmd::new::execute(name, Some(path)); + let result = execute(name, Some(path)); assert!(result.is_err(), "Should fail"); assert_eq!( @@ -137,7 +137,7 @@ mod tests { let dir = path.join(name); fs::create_dir_all(&dir).unwrap(); fs::File::create(dir.join(".gitignore")).unwrap(); - let result = cmd::new::execute(name, Some(path)); + let result = execute(name, Some(path)); assert!(result.is_err(), "Should fail"); assert_eq!(