Commit e22233d
fix(tests): place vector_enabled conditional at column 0
The `{% if vector_enabled -%}` and `{%- endif %}` blocks had
6 leading spaces. When vector_enabled was false, jinja2's strip
markers joined the leading whitespace of both blocks, putting
YAMLEOF at 12 spaces in the rendered output. After the kuttl
YAML block scalar strips 6 common-leading spaces, YAMLEOF ended
up at 6 spaces inside the script body, but the heredoc opener
is `<<'YAMLEOF'` (not `<<-`), which requires the terminator at
column 0. The heredoc therefore never closed and `\$(...)` never
terminated, producing `Syntax error: end of file unexpected
(expecting ")")` from dash.
Moving `{% if %}` and `{% endif %}` to column 0 (no strip markers)
mirrors kafka-operator's 34-assert.yaml.j2 pattern and renders
both branches with YAMLEOF at the correct indent.
Verified:
- non-vector render: 8 scripts pass against
kuttl-test-fluent-mastodon
- vector render heredoc parses to the 5 expected keys
(jvm.config, log4j2.properties, runtime.properties,
security.properties, vector.yaml)
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 282b0e5 commit e22233d
1 file changed
Lines changed: 10 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
724 | 724 | | |
725 | 725 | | |
726 | 726 | | |
727 | | - | |
| 727 | + | |
728 | 728 | | |
729 | 729 | | |
730 | | - | |
| 730 | + | |
731 | 731 | | |
732 | 732 | | |
733 | 733 | | |
| |||
830 | 830 | | |
831 | 831 | | |
832 | 832 | | |
833 | | - | |
| 833 | + | |
834 | 834 | | |
835 | 835 | | |
836 | | - | |
| 836 | + | |
837 | 837 | | |
838 | 838 | | |
839 | 839 | | |
| |||
936 | 936 | | |
937 | 937 | | |
938 | 938 | | |
939 | | - | |
| 939 | + | |
940 | 940 | | |
941 | 941 | | |
942 | | - | |
| 942 | + | |
943 | 943 | | |
944 | 944 | | |
945 | 945 | | |
| |||
1039 | 1039 | | |
1040 | 1040 | | |
1041 | 1041 | | |
1042 | | - | |
| 1042 | + | |
1043 | 1043 | | |
1044 | 1044 | | |
1045 | | - | |
| 1045 | + | |
1046 | 1046 | | |
1047 | 1047 | | |
1048 | 1048 | | |
| |||
1140 | 1140 | | |
1141 | 1141 | | |
1142 | 1142 | | |
1143 | | - | |
| 1143 | + | |
1144 | 1144 | | |
1145 | 1145 | | |
1146 | | - | |
| 1146 | + | |
1147 | 1147 | | |
1148 | 1148 | | |
1149 | 1149 | | |
| |||
0 commit comments