each_is_boolean

Function each_is_boolean 

Source
pub fn each_is_boolean() -> JsonPredicateMatcher<impl Fn(&Value) -> bool, String, &'static str>
Expand description

Matches JSON arrays whose elements are all JSON booleans.

ยงExamples

assert_that!(j!([true, false]), json::each_is_boolean());
assert_that!(j!([true, 1]), not(json::each_is_boolean()));