]> git.ipfire.org Git - thirdparty/tornado.git/commitdiff
Use add_callback to trigger ioloop in test. 767/head
authorhomm <homm86@gmail.com>
Sun, 28 Apr 2013 21:32:53 +0000 (01:32 +0400)
committerhomm <homm86@gmail.com>
Sun, 28 Apr 2013 21:32:53 +0000 (01:32 +0400)
tornado/test/gen_test.py

index 06dbf879965e2d9798c521ba3a8cc8a944babdf4..27c10eefdba64aae17315cf069a75939d3beae2f 100644 (file)
@@ -503,7 +503,7 @@ class GenEngineTest(AsyncTestCase):
 
         @gen.engine
         def f():
-            yield Task(lambda _arg, callback: callback(), Task(None))
+            yield Task(self.io_loop.add_callback, arg=Task(None))
             self.stop()
 
         self.run_gen(f)