diff --git a/exercises/test2.rs b/exercises/test2.rs index 249abbc..9d844f6 100755 --- a/exercises/test2.rs +++ b/exercises/test2.rs @@ -17,6 +17,11 @@ mod tests { #[test] fn returns_twice_of_positive_numbers() { - assert_eq!(4, 4); + assert_eq!(4, times_two(2)); + } + + #[test] + fn returns_twice_of_negative_numbers() { + assert_eq!(-4, times_two(-2)); } } diff --git a/exercises/tests/tests1.rs b/exercises/tests/tests1.rs index b11221f..8ad5d27 100755 --- a/exercises/tests/tests1.rs +++ b/exercises/tests/tests1.rs @@ -10,7 +10,7 @@ mod tests { #[test] fn you_can_assert() { - assert!(); + assert!(true); } } diff --git a/exercises/tests/tests2.rs b/exercises/tests/tests2.rs index 6775d61..8b7e790 100755 --- a/exercises/tests/tests2.rs +++ b/exercises/tests/tests2.rs @@ -6,7 +6,7 @@ mod tests { #[test] fn you_can_assert_eq() { - assert_eq!(); + assert_eq!(5,5); } } diff --git a/exercises/tests/tests3.rs b/exercises/tests/tests3.rs index e10d2aa..9dca033 100755 --- a/exercises/tests/tests3.rs +++ b/exercises/tests/tests3.rs @@ -13,7 +13,12 @@ mod tests { #[test] fn is_true_when_even() { - assert!(); + assert!(is_even(6)); + } + + #[test] + fn is_false_when_odd() { + assert!(!is_even(5)); } }