def test_negative(self):
     """
     If the list contains an object of the type, return False.
     """
     self.assertFalse(
         _contains_instance_of([object(), list(), {}], tuple)
     )
 def test_positive(self):
     """
     If the list contains an object of the type, return True.
     """
     self.assertTrue(
         _contains_instance_of([object(), tuple(), object()], tuple)
     )
Exemple #3
0
 def test_negative(self):
     """
     If the list does not contain an object of the type, return False.
     """
     assert not _contains_instance_of([object(), list(), {}], tuple)
Exemple #4
0
 def test_positive(self):
     """
     If the list contains an object of the type, return True.
     """
     assert _contains_instance_of([object(), tuple(), object()], tuple)
 def test_negative(self):
     """
     If the list does not contain an object of the type, return False.
     """
     assert not _contains_instance_of([object(), list(), {}], tuple)