def testDrawTextRectFStrEcho(self): overload = Overload() self.assertEqual(overload.drawText(RectF(), Str()), Overload.Function4) self.assertEqual(overload.drawText(RectF(), ''), Overload.Function4) self.assertEqual(overload.drawText(RectF(), Str(), Echo()), Overload.Function4) self.assertEqual(overload.drawText(RectF(), '', Echo()), Overload.Function4) self.assertEqual(overload.drawText(Rect(), Str()), Overload.Function4) self.assertEqual(overload.drawText(Rect(), ''), Overload.Function4) self.assertEqual(overload.drawText(Rect(), Str(), Echo()), Overload.Function4) self.assertEqual(overload.drawText(Rect(), '', Echo()), Overload.Function4)
def testCallOperator(self): e = Echo() self.assertEqual(e("Hello", 3), "Hello3")
def testEcho(self): '''Test function added with const char * as arg''' x = 'Foobar' y = Echo().echo(x) self.assertEqual(x, y)