open_pql/functions/
in_range.rs

1use super::*;
2
3#[pqlfn(arg, rtn, eval)]
4pub fn in_range(hand: &Hand, range: &mut PQLRange) -> PQLBoolean {
5    range.is_satisfied(hand)
6}
7
8#[cfg(test)]
9mod tests {
10    use super::*;
11    use crate::*;
12
13    #[test]
14    fn test_in_range() {
15        let mut c = PQLRange::from_src("AA", PQLGame::default()).unwrap();
16
17        in_range(&cards!("AsAh"), &mut c);
18    }
19}