Пример #1
0
 def testFunctionReceivingComplexObjectAsArgument(self):
     '''Test function returning a C++ Complex object.'''
     pt = sample.transmuteComplexIntoPoint(complex(1.2, 3.4))
     # these assertions intentionally avoids to test the == operator,
     # it should have its own test cases.
     self.assertEqual(pt.x(), 1.2)
     self.assertEqual(pt.y(), 3.4)
Пример #2
0
 def testFunctionReceivingComplexObjectAsArgument(self):
     '''Test function returning a C++ Complex object.'''
     pt = sample.transmuteComplexIntoPoint(complex(1.2, 3.4))
     # these assertions intentionally avoids to test the == operator,
     # it should have its own test cases.
     self.assertEqual(pt.x(), 1.2)
     self.assertEqual(pt.y(), 3.4)