aboutsummaryrefslogtreecommitdiffstats
path: root/testing/tests/loops.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--testing/tests/loops.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/testing/tests/loops.rs b/testing/tests/loops.rs
index b5fac7c..3ce6185 100644
--- a/testing/tests/loops.rs
+++ b/testing/tests/loops.rs
@@ -46,7 +46,10 @@ fn test_precedence_for() {
let s = PrecedenceTemplate {
strings: vec!["A", "alfa", "1"],
};
- assert_eq!(s.render().unwrap(), "0. A2 (first)\n1. alfa4\n2. 16\n");
+ assert_eq!(
+ s.render().unwrap(),
+ "0. A2 (first)\n1. alfa4\n2. 16 (last)\n"
+ );
}
#[derive(Template)]
@@ -59,5 +62,8 @@ struct ForRangeTemplate {
#[test]
fn test_for_range() {
let s = ForRangeTemplate { init: -1, end: 1 };
- assert_eq!(s.render().unwrap(), "foo\nfoo\nbar\nbar\nfoo\nbar\nbar\n");
+ assert_eq!(
+ s.render().unwrap(),
+ "foo (first)\nfoo (last)\nbar\nbar\nfoo\nbar\nbar\n"
+ );
}