예제 #1
0
 def test(a: only(int)):
     return a
예제 #2
0
 def test_only(self):
     self.assertIsInstance(1, only(int))
     self.assertNotIsInstance(True, only(int))
예제 #3
0
 def test_only(self):
     self.assertIsInstance(1, only(int))
     self.assertNotIsInstance(True, only(int))
예제 #4
0
 def test(a: only(int)):
     return a