From: homm Date: Sun, 28 Apr 2013 21:32:53 +0000 (+0400) Subject: Use add_callback to trigger ioloop in test. X-Git-Tag: v3.1.0~95^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F767%2Fhead;p=thirdparty%2Ftornado.git Use add_callback to trigger ioloop in test. --- diff --git a/tornado/test/gen_test.py b/tornado/test/gen_test.py index 06dbf8799..27c10eefd 100644 --- a/tornado/test/gen_test.py +++ b/tornado/test/gen_test.py @@ -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)