def test_obj_wrapper_as_arg(self):
     a_1 = ObjectWrapper(TestClassA())
     a_2 = ObjectWrapper(TestClassA())
     b = ObjectWrapper(TestClassB())
     a_1.x = 1
     a_2.x = 2
     b.foo(a_1, a_2)
     self.assertEqual('[foo: ([x: int], [x: int]) -> int]',
                      str(b.__pydyty_type__))
 def test_obj_wrapper_as_kwarg(self):
     a_1 = ObjectWrapper(TestClassA())
     a_2 = ObjectWrapper(TestClassA())
     b = ObjectWrapper(TestClassB())
     a_1.x = 1
     a_2.x = 2
     b.bar(first=a_1, second=a_2)
     self.assertEqual('[bar: (first:[x: int], second:[x: int]) -> int]',
                      str(b.__pydyty_type__))
     b.baz(first=1, second=2)
     self.assertEqual('[bar: (first:[x: int], second:[x: int]) -> int,' +
                      ' baz: (first:int, second:int) -> int]',
                      str(b.__pydyty_type__))