diff options
| author | Botahamec <botahamec@outlook.com> | 2022-10-26 20:23:59 -0400 |
|---|---|---|
| committer | Botahamec <botahamec@outlook.com> | 2022-10-26 20:23:59 -0400 |
| commit | fc7dcf7652674d6f52653582306b9a1e860ea5ba (patch) | |
| tree | 5db4df7e3804118ac5a45b864aaf29fa616fcfb5 /src | |
Start
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs new file mode 100644 index 0000000..7d12d9a --- /dev/null +++ b/src/lib.rs @@ -0,0 +1,14 @@ +pub fn add(left: usize, right: usize) -> usize { + left + right +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn it_works() { + let result = add(2, 2); + assert_eq!(result, 4); + } +} |
