From c5469ba6723eaecc5797acc842d090e1b85afb60 Mon Sep 17 00:00:00 2001 From: Danny van Kooten Date: Fri, 20 Mar 2020 14:55:50 +0100 Subject: add filter: length --- tests/test_template.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests') diff --git a/tests/test_template.c b/tests/test_template.c index 6b2ca12..1ad131e 100644 --- a/tests/test_template.c +++ b/tests/test_template.c @@ -484,4 +484,11 @@ TEST(filter_wordcount) { free(output); } +TEST(filter_title) { + char *input = "{{ \"Hello world\" | length }}"; + char *output = template_string(input, NULL); + assert_str(output, "11"); + free(output); +} + END_TESTS \ No newline at end of file -- cgit v1.2.3