Gui: Check Python types using Base::PyTypeCheck

This commit is contained in:
marioalexis
2022-07-20 01:18:22 -03:00
committed by Uwe
parent 5cb31ece93
commit fa6cf56020
7 changed files with 64 additions and 64 deletions

View File

@@ -49,12 +49,12 @@ class PartGuiViewProviderTestCases(unittest.TestCase):
# https://github.com/FreeCAD/FreeCAD/pull/6850
box = self.Doc.addObject("Part::Box", "Box")
with self.assertRaises(TypeError):
box.ViewObject.canDragObject(None)
box.ViewObject.canDragObject(0)
with self.assertRaises(TypeError):
box.ViewObject.canDropObject(None)
box.ViewObject.canDropObject(0)
box.ViewObject.canDropObject()
with self.assertRaises(TypeError):
box.ViewObject.dropObject(box, None)
box.ViewObject.dropObject(box, 0)
def tearDown(self):
#closing doc