mirror of
https://github.com/tlsnotary/tlsn-utils.git
synced 2026-01-09 23:18:12 -05:00
20 lines
419 B
Rust
20 lines
419 B
Rust
#![no_main]
|
|
|
|
use std::collections::HashSet;
|
|
|
|
use libfuzzer_sys::fuzz_target;
|
|
|
|
use rangeset_fuzz::SmallSet;
|
|
|
|
use rangeset::*;
|
|
|
|
fuzz_target!(|r: (SmallSet, SmallSet)| {
|
|
let s1: RangeSet<u8> = r.0.into();
|
|
let s2: RangeSet<u8> = r.1.into();
|
|
|
|
let h1: HashSet<u8> = HashSet::from_iter(s1.iter());
|
|
let h2: HashSet<u8> = HashSet::from_iter(s2.iter());
|
|
|
|
assert_eq!(s1.is_subset(&s2), h1.is_subset(&h2));
|
|
});
|