From e35f12c07c8dde617006de844bf909f42cff762f Mon Sep 17 00:00:00 2001 From: Kristoffer Skare Date: Thu, 19 Dec 2024 13:54:05 +0100 Subject: [PATCH] Change test for model description with internal state params to expect the output and state in opposite order. --- tests/utils/test_modelDescription_builder.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/tests/utils/test_modelDescription_builder.py b/tests/utils/test_modelDescription_builder.py index 7476b93..2ba348f 100644 --- a/tests/utils/test_modelDescription_builder.py +++ b/tests/utils/test_modelDescription_builder.py @@ -56,13 +56,14 @@ def test_generate_model_description_with_internal_state_params(): variables = xml_structure.findall(".//ScalarVariable") assert xml_structure.getroot().tag == "fmiModelDescription" - assert variables[0].attrib["name"] == "state1" - assert variables[0].attrib["causality"] == "parameter" - assert variables[0][0].tag == "Real" - assert variables[0][0].attrib["start"] == "0.0" - assert variables[1].attrib["name"] == "output1" - assert variables[1].attrib["causality"] == "output" + assert variables[0].attrib["name"] == "output1" + assert variables[0].attrib["causality"] == "output" + + assert variables[1].attrib["name"] == "state1" + assert variables[1].attrib["causality"] == "parameter" + assert variables[1][0].tag == "Real" + assert variables[1][0].attrib["start"] == "0.0" def test_generate_vector_ports():