mirror of
https://github.com/pantor/inja.git
synced 2026-04-05 15:48:51 +00:00
fix and test
This commit is contained in:
@@ -165,6 +165,7 @@ TEST_CASE("Parse conditions") {
|
||||
data["age"] = 29;
|
||||
data["brother"] = "Peter";
|
||||
data["father"] = "Peter";
|
||||
data["guests"] = {"Jeff", "Seb"};
|
||||
|
||||
SECTION("Elements") {
|
||||
CHECK( env.parse_condition("age", data) );
|
||||
@@ -195,4 +196,9 @@ TEST_CASE("Parse conditions") {
|
||||
CHECK( env.parse_condition("brother == \"Peter\"", data) );
|
||||
CHECK_FALSE( env.parse_condition("not brother == father", data) );
|
||||
}
|
||||
|
||||
SECTION("Lists") {
|
||||
// CHECK( env.parse_condition("\"Jeff\" in guests", data) );
|
||||
CHECK_FALSE( env.parse_condition("brother in guests", data) );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user