diff options
author | SoniEx2 <endermoneymod@gmail.com> | 2022-08-06 15:06:18 -0300 |
---|---|---|
committer | SoniEx2 <endermoneymod@gmail.com> | 2022-08-06 15:06:18 -0300 |
commit | f24123f943abaebffd098a12069bcca62181f862 (patch) | |
tree | dd36cc3cafc0ec71fc388b610ec127bb53b657bf /tests/basic_match.rs | |
parent | a8778ff35bde88bb63d9fec769edf66e68d7969e (diff) |
Fix predicates
Diffstat (limited to 'tests/basic_match.rs')
-rw-r--r-- | tests/basic_match.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/basic_match.rs b/tests/basic_match.rs index 1500356..5c03a48 100644 --- a/tests/basic_match.rs +++ b/tests/basic_match.rs @@ -4,10 +4,12 @@ use serde_json::Deserializer as JsonDer; use serde::Deserialize; +use datafu::Predicate; + #[test] fn test_basic() { let mut der = JsonDer::from_str(r#"{"foo": 1, "bar": {"baz": 2}}"#); - let preds = vec![("dict", datafu::pred(|v| { todo!() }))].into_iter().collect(); + let preds = vec![("dict", datafu::pred(|v| { todo!(); false }))].into_iter().collect(); let pat = datafu::Pattern::<()>::compile::<&str, &str>("->[x]:?$dict->y[yk]", Some(preds), None).unwrap(); #[derive(Deserialize)] struct Values { |