1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
prelude!(); #[test] fn test_nested_mods() { let out: i64 = rune! { pub mod hello { pub mod inner { pub fn test() { 2 } } pub fn test() { 1 + inner::test() } } hello::test() }; assert_eq!(out, 3); }