Skip to content

Commit

Permalink
added specialization tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ronnodas committed Sep 10, 2024
1 parent b3a92a9 commit dc21323
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/specializations.rs
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,16 @@ quickcheck! {
test_specializations(&v.into_iter().intersperse_with(|| 0));
}

fn array_combinations(v: Vec<u8>) -> TestResult {
if v.len() > 10 {
return TestResult::discard();
}
test_specializations(&v.iter().array_combinations::<1>());
test_specializations(&v.iter().array_combinations::<2>());
test_specializations(&v.iter().array_combinations::<3>());
TestResult::passed()
}

fn combinations(a: Vec<u8>, n: u8) -> TestResult {
if n > 3 || a.len() > 8 {
return TestResult::discard();
Expand Down

0 comments on commit dc21323

Please sign in to comment.