1
0
Fork 0
mirror of synced 2024-12-21 22:21:08 -05:00
yadm/test
Erik Flodin 8ba9823407
Rewrite default template to handle nested ifs, != and env vars in if
The awk script now performs all processing in the BEGIN block using an
implementation that is capable of handling if statements which contain nested
if statments (fixes #436). To make nested ifs look better, if, else and endif
lines can now have optional whitespace before {%.

Includes are now handled in the same way as the main file which means that
included files can both include other files and have if statements in addition
to variables (fixes #406). Include lines can now also have optional whitespace
before {%.

All variables are handled in the same way now so it's now possible to use env
variables in if statements (fixes #488).

Also add support for != in addition to == (fixes #358). Thus it's now
e.g. possible to check if a variable is set (#477) by doing:

{% if yadm.class != ""%}
Class is set to {{ yadm.class }}
{% endif %}

A non-existing yadm or env variable is now replaced with the empty string.
2024-11-04 22:30:23 +01:00
..
conftest.py Changes for black compliance 2023-07-12 09:20:00 -05:00
Dockerfile Update test Docker image 2023-07-12 09:19:53 -05:00
ownertrust.txt Create acceptance tests for asymmetric encryption 2016-04-21 07:13:40 -05:00
pinentry-mock Adjust pinentry mock 2023-07-12 09:19:59 -05:00
requirements.txt Update test Docker image 2023-07-12 09:19:53 -05:00
test_alt.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_alt_copy.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_assert_private_dirs.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_bootstrap.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_clean.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_clone.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_config.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_encryption.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_enter.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_ext_crypt.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_git.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_help.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_hooks.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_init.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_introspect.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_key Create acceptance tests for asymmetric encryption 2016-04-21 07:13:40 -05:00
test_list.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_perms.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_syntax.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_bootstrap_available.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_choose_template_cmd.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_configure_paths.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_copy_perms.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_encryption.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_exclude_encrypted.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_issue_legacy_path_warning.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_parse_encrypt.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_private_dirs.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_query_distro.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_query_distro_family.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_record_score.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_record_template.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_relative_path.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_remove_stale_links.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_report_invalid_alts.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_score_file.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_set_local_alt_values.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_set_os.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_set_yadm_dir.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_template_default.py Rewrite default template to handle nested ifs, != and env vars in if 2024-11-04 22:30:23 +01:00
test_unit_template_esh.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_template_j2.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_upgrade.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_unit_x_program.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_upgrade.py Changes for black compliance 2023-07-12 09:20:00 -05:00
test_version.py Changes for black compliance 2023-07-12 09:20:00 -05:00
utils.py Changes for black compliance 2023-07-12 09:20:00 -05:00