From e9218711cf8e302bfcefef1fcc944e141f0f7e2a Mon Sep 17 00:00:00 2001
From: Alexander Schlemmer <alexander@mail-schlemmer.de>
Date: Mon, 10 Oct 2022 14:01:54 +0200
Subject: [PATCH] TST: corrected failing unit test

---
 unittests/test_macros.py | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/unittests/test_macros.py b/unittests/test_macros.py
index 29b59290..7ac34cc7 100644
--- a/unittests/test_macros.py
+++ b/unittests/test_macros.py
@@ -295,7 +295,7 @@ extroot3: !macro
     assert cfood["extroot3"]["test_four"] is None
 
 
-@pytest.mark.xfail(reason="Fix multiple usage of the same macro.")
+# @pytest.mark.xfail(reason="Fix multiple usage of the same macro.")
 def test_use_macro_twice():
     """Test that the same macro can be used twice with different parameters in
     the same CFood element if the name depends on the parameters.
@@ -318,14 +318,13 @@ metadata:
 ---
 extroot: !macro
   test_twice:
-    macro_name: once
-  test_twice:
-    macro_name: twice
+  - macro_name: once
+  - macro_name: twice
     a: 5
-  test_twice:
+  - {}
     """)
     for name in ["once", "twice", "default_name"]:
         assert name in cfood["extroot"]
-    assert cfood["extroot"]["once"]["something"]["a"] == 4
-    assert cfood["extroot"]["twice"]["something"]["a"] == 5
-    assert cfood["extroot"]["default_name"]["something"]["a"] == 4
+    assert cfood["extroot"]["once"]["something"]["a"] == "4"
+    assert cfood["extroot"]["twice"]["something"]["a"] == "5"
+    assert cfood["extroot"]["default_name"]["something"]["a"] == "4"
-- 
GitLab