diff --git a/integration-tests/templates/comment.out b/integration-tests/templates/comment.out new file mode 100644 index 0000000..cc32087 --- /dev/null +++ b/integration-tests/templates/comment.out @@ -0,0 +1 @@ +10001 diff --git a/integration-tests/templates/comment.stpl b/integration-tests/templates/comment.stpl new file mode 100644 index 0000000..3bfb725 --- /dev/null +++ b/integration-tests/templates/comment.stpl @@ -0,0 +1 @@ +<%= 1 + /* 10 + %> /* 100 + */ 1000 %> + */ 10000 %> diff --git a/integration-tests/tests/template_once.rs b/integration-tests/tests/template_once.rs index f838ead..83a3e7a 100644 --- a/integration-tests/tests/template_once.rs +++ b/integration-tests/tests/template_once.rs @@ -164,6 +164,15 @@ fn test_rm_whitespace() { ); } +#[derive(TemplateOnce)] +#[template(path = "comment.stpl")] +struct Comment {} + +#[test] +fn test_comment() { + assert_render("comment", Comment{}) +} + #[cfg(unix)] mod unix { use super::*;