Skip to content

Commit 19ffb0a

Browse files
committed
test: Add test for next-line conditional
1 parent f055ac1 commit 19ffb0a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/tests/yolk_tests.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -495,6 +495,8 @@ pub fn test_only_active_sections_get_evaluated() -> TestResult {
495495
{% else %}
496496
{< "1" >}
497497
{% end %}
498+
{# if false #}
499+
{< bad_code() >}
498500
"#};
499501
assert_str_eq!(
500502
indoc::indoc! {r#"
@@ -503,6 +505,8 @@ pub fn test_only_active_sections_get_evaluated() -> TestResult {
503505
{% else %}
504506
1{< "1" >}
505507
{% end %}
508+
{# if false #}
509+
#<yolk> {< bad_code() >}
506510
"#},
507511
yolk.eval_template(&mut eval_ctx, "", template)?
508512
);

0 commit comments

Comments
 (0)