Radish alpha
h
rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5
Radicle Heartwood Protocol & Stack
Radicle
Git
heartwood crates radicle-protocol src fetcher test queue properties equality.rs
use qcheck_macros::quickcheck;

use crate::fetcher::QueuedFetch;

#[quickcheck]
fn reflexive(item: QueuedFetch) -> bool {
    item == item.clone()
}

#[quickcheck]
fn symmetric(a: QueuedFetch, b: QueuedFetch) -> bool {
    (a == b) == (b == a)
}

#[quickcheck]
fn transitive(a: QueuedFetch, b: QueuedFetch, c: QueuedFetch) -> bool {
    if a == b && b == c { a == c } else { true }
}