Пример #1
0
    def test_should_extend_list(self):
        # given
        lst1 = TypedList((int,), *[1, 2, 3])
        lst2 = TypedList((int,), *[4, 5])

        # when
        lst1.extend(lst2)

        # then
        extended = TypedList((int,), *[1, 2, 3, 4, 5])
        assert lst1 == extended
Пример #2
0
    def test_should_extend_list(self):
        # given
        lst1 = TypedList(*[1, 2, 3], oktypes=(int, ))
        lst2 = TypedList(*[4, 5], oktypes=(int, ))

        # when
        lst1.extend(lst2)

        # then
        extended = TypedList(*[1, 2, 3, 4, 5], oktypes=(int, ))
        assert lst1 == extended