Skip to content
Snippets Groups Projects
Commit c915e830 authored by florian's avatar florian
Browse files

TST: Add test for recursion of macros

parent 428de240
No related branches found
No related tags found
2 merge requests!53Release 0.1,!25F macros
Pipeline #28935 failed
......@@ -272,11 +272,18 @@ metadata:
params: {}
definition: !macro
test_two:
- !defmacro
name: test_four
params: {}
definition: !macro
test_four:
---
extroot: !macro
test_one:
extroot2: !macro
test_three:
extroot3: !macro
test_four:
""")
# macros in macros can be used, but there are no circles; they stop at the first one.
assert "test_one" not in cfood["extroot"]
......@@ -284,3 +291,5 @@ extroot2: !macro
assert "test_three" not in cfood["extroot2"]
assert "test_one" not in cfood["extroot2"]
assert cfood["extroot2"]["test_two"] is None
# No recursion
assert cfood["extroot3"]["test_four"] is None
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment