def setUp(self):
        import GEOM
        import SMESH
        import salome
        bld = aster_s.StudyBuilder()
        std = bld.create_salome_study("std")
        sidx = std.idx
        sstd = std.sstd

        geng = salome.lcc.FindOrLoadComponent("FactoryServer", "GEOM")
        basic_ops = geng.GetIBasicOperations(sidx)
        prim_ops = geng.GetI3DPrimOperations(sidx)
        sgeom = prim_ops.MakeBoxDXDYDZ(5, 5, 5)
        geng.AddInStudy(sstd, sgeom, "3D", None)

        seng = salome.lcc.FindOrLoadComponent("FactoryServer", "SMESH")
        seng.SetCurrentStudy(sstd)
        mesh = std.attach_mesh_from(seng.CreateMesh(sgeom))

        self.std = std
        self.sstd = sstd
        self.geng = geng
        self.basic_ops = basic_ops
        self.prim_ops = prim_ops
        self.sgeom = sgeom
        self.mesh = mesh
    def setUp(self):
        bld = aster_s.StudyBuilder()
        sstd = bld.create_salome_study("std", register=True)
        astd = bld.attach_to(sstd)

        ceng = salome.lcc.FindOrLoadComponent("FactoryServerPy", "ASTER")
        eng = ceng._narrow(ASTER.ASTER_Gen)
        cstd = eng.AttachTo(sstd.sstd)

        self.bld = bld
        self.sstd = sstd
        self.astd = astd
        self.cstd = cstd
    def setUp(self):
        bld = aster_s.StudyBuilder()
        sstd = bld.create_salome_study("std", register=True)
        astd = aster_s.Study(sstd)

        ceng = salome.lcc.FindOrLoadComponent("FactoryServerPy", "ASTER")
        eng = ceng._narrow(ASTER.ASTER_Gen)
        cstd = eng.AttachTo(sstd.sstd)

        self.bld = bld
        self.astd = astd
        self.cstd = cstd
        self.srv = build_srv()
        self.tmp_dir = SAT.TmpDir("run_cases_by_using_corba")
    def setUp(self):
        bld = aster_s.StudyBuilder()
        std = bld.create("std")

        # Creating fake Eficas file because the
        # EFICAS component does not offer an interface
        name = "eficas-file.comm"
        ftype = ST.EficasFile.ftype
        fname = "/aster/case1/eficas-file.comm"
        node = std.node.add_node(name)
        node.get_attr(ST.Type).write(ftype)
        node.get_attr(ST.Value).write(fname)

        self.std = std
        self.fdata = {
            "node": node,
            "name": name,
            "ftype": ftype,
            "fname": fname,
        }
 def setUp(self):
     self.bld = aster_s.StudyBuilder()
     self.sstd = self.bld.create_salome_study("std", register=True).sstd
 def setUp(self):
     self.bld = aster_s.StudyBuilder()
     self.std = self.bld.create("s")
     self.aster_version = aster_s.build_default_cfg()["aster-version"].value
     self.tmp_dir = AT.TmpDir("run_aster_from_salome")
Beispiel #7
0
 def setUp(self):
     self.bld = aster_s.StudyBuilder()
     self.std = self.bld.create("std")
Beispiel #8
0
 def setUp(self):
     self.bld = aster_s.StudyBuilder()
     self.std = self.bld.create("std")
     self._display_med_file = ST.VisuMedFile.display
     ST.VisuMedFile.display = False
 def setUp(self):
     self.bld = aster_s.StudyBuilder()
     self.mng = salome.myStudyManager
    def test_avoid_opening_of_salome_study_on_start(self):
        bld = aster_s.StudyBuilder()

        mng = salome.myStudyManager
        self.assertEqual(mng.GetOpenStudies(), [])
 def test_keep_the_same_study_builder_for_every_study(self):
     bld = aster_s.StudyBuilder()
     self.assert_(aster_s.StudyBuilder() is bld)
 def test_initialize_life_cycle_corba(self):
     bld = aster_s.StudyBuilder()
     self.assert_(salome.lcc is not None)
 def setUp(self):
     import salome_aster_tests as ST
     bld = aster_s.StudyBuilder()
     self.std = bld.create_salome_study("std")
     self.med_fname = ST.get_data("forma01a.mmed")
     self.tmp_dir = ST.TmpDir("manipulate_meshes")
 def setUp(self):
     bld = aster_s.StudyBuilder()
     self.std = bld.create_salome_study("s")
 def setUp(self):
     bld = aster_s.StudyBuilder()
     self.std = bld.create_salome_study("s")
     self.pal_std = SAT.PalStudyBuilder().attach_to(self.std)