Exemplo n.º 1
0
def test_material_ifc_roundtrip(materials_test_dir):
    ifc_path = materials_test_dir / "my_material.ifc"

    p = Part("MyPart")
    p.add_material(Material("my_mat"))
    a = Assembly("MyAssembly") / p
    fp = a.to_ifc(ifc_path, return_file_obj=True)

    b = ada.from_ifc(fp)
    assert len(b.materials) == 1
Exemplo n.º 2
0
    def test_material_ifc_roundtrip(self):

        ifc_name = "my_material.ifc"

        a = Assembly("MyAssembly")
        p = Part("MyPart")
        p.add_material(Material("my_mat"))
        a.add_part(p)
        a.to_ifc(test_folder / ifc_name)

        b = Assembly("MyImport")
        b.read_ifc(test_folder / ifc_name)
Exemplo n.º 3
0
    def test_material_ifc_roundtrip(self):

        ifc_name = 'my_material.ifc'

        a = Assembly('MyAssembly')
        p = Part('MyPart')
        p.add_material(Material('my_mat'))
        a.add_part(p)
        a.to_ifc(test_folder / ifc_name)

        b = Assembly('MyImport')
        b.read_ifc(test_folder / ifc_name)