17 lines
251 B
Rust
17 lines
251 B
Rust
|
use next_prime::next_prime;
|
||
|
|
||
|
#[test]
|
||
|
fn first_example() {
|
||
|
assert_eq!(next_prime(12), Some(13));
|
||
|
}
|
||
|
|
||
|
#[test]
|
||
|
fn second_example() {
|
||
|
assert_eq!(next_prime(24), Some(29));
|
||
|
}
|
||
|
|
||
|
#[test]
|
||
|
fn third_example() {
|
||
|
assert_eq!(next_prime(11), Some(11));
|
||
|
}
|