1
Fork 0

Use assert_eq! rather than assert! where possible

This commit is contained in:
Corey Richardson 2013-05-18 22:02:45 -04:00
parent 3acf37897a
commit cc57ca012a
641 changed files with 2809 additions and 2809 deletions

View file

@ -19,7 +19,7 @@ struct I { i: int }
fn test_rec() {
let rs = if true { I {i: 100} } else { I {i: 101} };
assert!((rs.i == 100));
assert_eq!(rs.i, 100);
}
enum mood { happy, sad, }
@ -33,7 +33,7 @@ impl cmp::Eq for mood {
fn test_tag() {
let rs = if true { happy } else { sad };
assert!((rs == happy));
assert_eq!(rs, happy);
}
pub fn main() { test_rec(); test_tag(); }