Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
berndhahnebach committed May 22, 2019
1 parent 150b659 commit d696a42
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions src/Mod/Fem/femtest/testcmdproblem.py
Expand Up @@ -64,6 +64,28 @@ def test_cmdproblem(self):
from femmesh.meshtools import get_femnodes_by_refshape as getnodes
getnodes(femmesh, ref)

def test_face_subclass1(self):

import Part
box=Part.makeBox(1,1,1)
fcc_print('\n')
fcc_print(box)
fcc_print(box.ShapeType)
face = box.Face1
fcc_print(issubclass(type(face), Part.Face))

def test_face_subclass2(self):

box = self.active_doc.addObject(
"Part::Box",
"Box"
)
fcc_print('\n')
fcc_print(box.Shape)
fcc_print(box.Shape.ShapeType)
#face = box.Face1
#fcc_print(issubclass(type(face), Part.Face))

def tearDown(self):
# clearance, is executed after every test
FreeCAD.closeDocument(self.doc_name)
Expand All @@ -73,6 +95,14 @@ def tearDown(self):
'''
https://forum.freecadweb.org/viewtopic.php?f=10&t=36543
make -j4 && ./bin/FreeCADCmd --run-test "femtest.testcmdproblem.TestCmdProblem.test_face_subclass1"
make -j4 && ./bin/FreeCADCmd --run-test "femtest.testcmdproblem.TestCmdProblem.test_face_subclass2"
import unittest
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.testcmdproblem.TestCmdProblem.test_face_subclass1"))
unittest.TextTestRunner().run(unittest.TestLoader().loadTestsFromName("femtest.testcmdproblem.TestCmdProblem.test_face_subclass2"))
make -j4 && ./bin/FreeCADCmd --run-test "femtest.testcmdproblem.TestCmdProblem.test_cmdproblem"
import unittest
Expand Down

0 comments on commit d696a42

Please sign in to comment.