aboutsummaryrefslogtreecommitdiffstats
path: root/testing/tests/simple.rs
diff options
context:
space:
mode:
authorLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2017-10-22 14:26:38 +0200
committerLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2017-10-22 14:26:38 +0200
commit14beb21d0cef62ca47ad85617bd9460369a15b61 (patch)
treef11fa0f65f0bb212f256ef679e2b9c73c2eb77dd /testing/tests/simple.rs
parentfef994d2f678a56b08f37043c306cfbf4a93427b (diff)
downloadaskama-14beb21d0cef62ca47ad85617bd9460369a15b61.tar.gz
askama-14beb21d0cef62ca47ad85617bd9460369a15b61.tar.bz2
askama-14beb21d0cef62ca47ad85617bd9460369a15b61.zip
Make empty string literals work
Diffstat (limited to 'testing/tests/simple.rs')
-rw-r--r--testing/tests/simple.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/testing/tests/simple.rs b/testing/tests/simple.rs
index bee5690..37027b7 100644
--- a/testing/tests/simple.rs
+++ b/testing/tests/simple.rs
@@ -187,11 +187,11 @@ fn test_path_compare() {
#[derive(Template)]
-#[template(source = "{% for i in [1, 2] %}{{ i }}{% endfor %}", ext = "txt")]
+#[template(source = "{% for i in [\"a\", \"\"] %}{{ i }}{% endfor %}", ext = "txt")]
struct ArrayTemplate {}
#[test]
fn test_slice_literal() {
let t = ArrayTemplate {};
- assert_eq!(t.render().unwrap(), "12");
+ assert_eq!(t.render().unwrap(), "a");
}