MCPcopy
hub / github.com/tornadoweb/tornado / test_multi_performance

Method test_multi_performance

tornado/test/gen_test.py:143–150  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

141
142 @gen_test
143 def test_multi_performance(self):
144 # Yielding a list used to have quadratic performance; make
145 # sure a large list stays reasonable. On my laptop a list of
146 # 2000 used to take 1.8s, now it takes 0.12.
147 start = time.time()
148 yield [gen.moment for i in range(2000)]
149 end = time.time()
150 self.assertLess(end - start, 1.0)
151
152 @gen_test
153 def test_multi_empty(self):

Callers

nothing calls this directly

Calls 1

timeMethod · 0.80

Tested by

no test coverage detected