diff --git a/test/main.rs b/test/main.rs index b7803f5..3fd5e9a 100644 --- a/test/main.rs +++ b/test/main.rs @@ -1,8 +1,10 @@ mod elo; +mod subdir; use std::io; -use crate::elo; +use crate::subdir::subdirfile; fn main() { println!("{}", elo::lebo()); + println!("{}", subdirfile::my_life()); } \ No newline at end of file diff --git a/test/output.rs b/test/output.rs new file mode 100644 index 0000000..d524040 --- /dev/null +++ b/test/output.rs @@ -0,0 +1,21 @@ +mod elo { +pub fn lebo() -> String { + String::from("ELO") +} +} +mod subdir { +pub mod subdirfile { +pub fn my_life() -> String { + String::from("MY LIFE") +} +} + +} + +use std::io; +use crate::subdir::subdirfile; + +fn main() { + println!("{}", elo::lebo()); + println!("{}", subdirfile::my_life()); +} diff --git a/test/subdir/mod.rs b/test/subdir/mod.rs new file mode 100644 index 0000000..8a4d31a --- /dev/null +++ b/test/subdir/mod.rs @@ -0,0 +1 @@ +pub mod subdirfile; \ No newline at end of file diff --git a/test/subdir/subdirfile.rs b/test/subdir/subdirfile.rs new file mode 100644 index 0000000..b00dc71 --- /dev/null +++ b/test/subdir/subdirfile.rs @@ -0,0 +1,3 @@ +pub fn my_life() -> String { + String::from("MY LIFE") +} \ No newline at end of file