aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--askama_derive/src/lib.rs3
-rw-r--r--testing/tests/filters.rs10
-rw-r--r--testing/tests/simple.rs10
3 files changed, 17 insertions, 6 deletions
diff --git a/askama_derive/src/lib.rs b/askama_derive/src/lib.rs
index 5591b82..45d98b9 100644
--- a/askama_derive/src/lib.rs
+++ b/askama_derive/src/lib.rs
@@ -186,8 +186,7 @@ impl<'a> Context<'a> {
} else {
unreachable!()
}
- })
- .collect();
+ }).collect();
Context {
nodes,
diff --git a/testing/tests/filters.rs b/testing/tests/filters.rs
index d665df9..8c654c1 100644
--- a/testing/tests/filters.rs
+++ b/testing/tests/filters.rs
@@ -133,7 +133,10 @@ fn test_nested_filter_ref() {
}
#[derive(Template)]
-#[template(source = "{% let p = baz.print(foo.as_ref()) %}{{ p|upper }}", ext = "html")]
+#[template(
+ source = "{% let p = baz.print(foo.as_ref()) %}{{ p|upper }}",
+ ext = "html"
+)]
struct FilterLetFilterTemplate {
foo: String,
baz: Baz,
@@ -157,7 +160,10 @@ fn test_filter_let_filter() {
}
#[derive(Template)]
-#[template(source = "{{ foo|truncate(10) }}{{ foo|truncate(5) }}", ext = "txt")]
+#[template(
+ source = "{{ foo|truncate(10) }}{{ foo|truncate(5) }}",
+ ext = "txt"
+)]
struct TruncateFilter {
foo: String,
}
diff --git a/testing/tests/simple.rs b/testing/tests/simple.rs
index 4af2cea..9575daa 100644
--- a/testing/tests/simple.rs
+++ b/testing/tests/simple.rs
@@ -182,7 +182,10 @@ enum Alphabet {
}
#[derive(Template)]
-#[template(source = "{% if x == Alphabet::Alpha %}true{% endif %}", ext = "txt")]
+#[template(
+ source = "{% if x == Alphabet::Alpha %}true{% endif %}",
+ ext = "txt"
+)]
struct PathCompareTemplate {
x: Alphabet,
}
@@ -194,7 +197,10 @@ fn test_path_compare() {
}
#[derive(Template)]
-#[template(source = "{% for i in [\"a\", \"\"] %}{{ i }}{% endfor %}", ext = "txt")]
+#[template(
+ source = "{% for i in [\"a\", \"\"] %}{{ i }}{% endfor %}",
+ ext = "txt"
+)]
struct ArrayTemplate {}
#[test]