MCPcopy
hub / github.com/celery/celery / test_list

Method test_list

t/unit/utils/test_functional.py:91–100  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

89class test_regen:
90
91 def test_list(self):
92 l = [1, 2]
93 r = regen(iter(l))
94 assert regen(l) is l
95 assert r == l
96 assert r == l # again
97 assert r.__length_hint__() == 0
98
99 fun, args = r.__reduce__()
100 assert fun(*args) == l
101
102 @pytest.fixture
103 def g(self):

Callers

nothing calls this directly

Calls 4

regenFunction · 0.90
funFunction · 0.85
__length_hint__Method · 0.45
__reduce__Method · 0.45

Tested by

no test coverage detected