initial commit
This commit is contained in:
4
exercises/04_traits/00_intro/Cargo.toml
Normal file
4
exercises/04_traits/00_intro/Cargo.toml
Normal file
@@ -0,0 +1,4 @@
|
||||
[package]
|
||||
name = "intro_03"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
14
exercises/04_traits/00_intro/src/lib.rs
Normal file
14
exercises/04_traits/00_intro/src/lib.rs
Normal file
@@ -0,0 +1,14 @@
|
||||
fn intro() -> &'static str {
|
||||
// TODO: fix me 👇
|
||||
"I'm ready to __!"
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use crate::intro;
|
||||
|
||||
#[test]
|
||||
fn test_intro() {
|
||||
assert_eq!(intro(), "I'm ready to learn about traits!");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user