Пример #1
0
 def test_is_sequence_various(self):
     self.assertTrue(util.is_sequence([]))
     self.assertTrue(util.is_sequence(tuple()))
     self.assertTrue(util.is_sequence(set()))
Пример #2
0
 def test_is_sequence_various(self):
     self.assertTrue(is_sequence([]))
     self.assertTrue(is_sequence(tuple()))
     self.assertTrue(is_sequence(set()))
Пример #3
0
def get_sequence_item_type(cls):
    if cls and util.is_sequence(cls):
        return get_obj_cls(cls.__iter__().next())
    return None