cargo test
#[test]
fn hoge() {
...
}
assert!(true); // true チェック
assert_eq!(10 - 1, 9); // 一致
assert_ne!(10 - 9, 9); // 不一致
#[test]
#[should_panic(expected = "Panic !!!!!!!")]
fn hoge() {
panic!("Panic !!!!!!!");
}
#[test]
#[ignore]
fn hoge() {
...
}