From 699c8bf6b6ceaa077406785052a94f9602017953 Mon Sep 17 00:00:00 2001 From: Sigma Dimensions Date: Mon, 29 Aug 2022 12:50:38 +0100 Subject: [PATCH] fix path windows test-bim --- src/blenderbim/test/bim/test_feature.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/blenderbim/test/bim/test_feature.py b/src/blenderbim/test/bim/test_feature.py index 949ce74939..6f8bfd38be 100644 --- a/src/blenderbim/test/bim/test_feature.py +++ b/src/blenderbim/test/bim/test_feature.py @@ -36,6 +36,8 @@ webbrowser.open = lambda x: True def replace_variables(value): + if "{cwd}" in value and os.name == "nt": + value = value.replace("/", "\\").replace("{cwd}", os.getcwd()).replace("\\", "\\\\") for key, new_value in variables.items(): value = value.replace("{" + key + "}", str(new_value)) return value @@ -633,9 +635,7 @@ def i_display_the_construction_type_browser(): @when("I add the construction type") def i_add_the_active_construction_type(): props = bpy.context.scene.BIMModelProperties - bpy.ops.bim.add_constr_type_instance( - ifc_class=props.ifc_class, relating_type_id=int(props.relating_type_id) - ) + bpy.ops.bim.add_constr_type_instance(ifc_class=props.ifc_class, relating_type_id=int(props.relating_type_id)) @then(parsers.parse("construction type is {relating_type_name}"))