MCPcopy Create free account
hub / github.com/Kitware/VTK / testObjectConstructor

Method testObjectConstructor

Common/Core/Testing/Python/TestVariant.py:86–92  ·  view source on GitHub ↗

Construct from VTK object

(self)

Source from the content-addressed store, hash-verified

84 self.assertEqual(v.ToString(), cedilla)
85
86 def testObjectConstructor(self):
87 """Construct from VTK object"""
88 o = vtkIntArray()
89 v = vtkVariant(o)
90 self.assertEqual(v.GetType(), VTK_OBJECT)
91 self.assertEqual(v.GetTypeAsString(), o.GetClassName())
92 self.assertEqual(v.ToVTKObject(), o)
93
94 def testTwoArgConstructor(self):
95 """Construct with a specific type"""

Callers

nothing calls this directly

Calls 6

vtkIntArrayFunction · 0.50
vtkVariantClass · 0.50
GetTypeMethod · 0.45
GetTypeAsStringMethod · 0.45
GetClassNameMethod · 0.45
ToVTKObjectMethod · 0.45

Tested by

no test coverage detected