()
| 947 | |
| 948 | #[test] |
| 949 | fn test_builder_equal() { |
| 950 | let pb = PredicateBuilder::new(&test_fields()); |
| 951 | let pred = pb.equal("id", Datum::Int(42)).unwrap(); |
| 952 | |
| 953 | match &pred { |
| 954 | Predicate::Leaf { |
| 955 | column, |
| 956 | index, |
| 957 | op, |
| 958 | literals, |
| 959 | .. |
| 960 | } => { |
| 961 | assert_eq!(column, "id"); |
| 962 | assert_eq!(*index, 0); |
| 963 | assert_eq!(*op, PredicateOperator::Eq); |
| 964 | assert_eq!(literals, &[Datum::Int(42)]); |
| 965 | } |
| 966 | other => panic!("expected Leaf, got {other:?}"), |
| 967 | } |
| 968 | } |
| 969 | |
| 970 | #[test] |
| 971 | fn test_builder_comparison_ops() { |
nothing calls this directly
no test coverage detected