1 mod src; 2 mod submodule; 3 forty_two_as_string() -> String4pub fn forty_two_as_string() -> String { 5 format!("{}", src::forty_two()) 6 } 7 8 #[cfg(test)] 9 mod test { 10 #[test] test_forty_two()11 fn test_forty_two() { 12 assert_eq!(super::src::forty_two(), 42); 13 } 14 15 #[test] test_forty_two_as_string()16 fn test_forty_two_as_string() { 17 assert_eq!(super::forty_two_as_string(), "42"); 18 } 19 } 20