Skip to content

Commit

Permalink
Don't use should_panic
Browse files Browse the repository at this point in the history
  • Loading branch information
smrtrfszm committed Jul 29, 2024
1 parent 3a027bb commit b2760d7
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions iam-common/src/id.rs
Original file line number Diff line number Diff line change
Expand Up @@ -171,21 +171,21 @@ mod tests {
}

#[test]
#[should_panic]
fn from_str_invalid_type() {
Id::from_str("Invalid-00000000-0000-0000-0000-000000000000").unwrap();
let id = Id::from_str("Invalid-00000000-0000-0000-0000-000000000000");
assert!(id.is_err());
}

#[test]
#[should_panic]
fn from_str_invalid_uuid() {
Id::from_str("UserID-invalid").unwrap();
let id = Id::from_str("UserID-invalid");
assert!(id.is_err());
}

#[test]
#[should_panic]
fn from_str_invalid_format() {
Id::from_str("invalid").unwrap();
let id = Id::from_str("invalid");
assert!(id.is_err());
}

#[test]
Expand Down

0 comments on commit b2760d7

Please sign in to comment.