def setUp(self): from mousetrap.core import Loop self.gdk_patcher = GtkGdkPatch() self.gdk_patcher.patch_in_setup(test_case=self) self.config = {'loops_per_second': 10} self.loop = Loop(self.config, app=None)
class test_Loop(unittest.TestCase): def setUp(self): from mousetrap.core import Loop self.gdk_patcher = GtkGdkPatch() self.gdk_patcher.patch_in_setup(test_case=self) self.config = {'loops_per_second': 10} self.loop = Loop(self.config, app=None) def test_loop(self): self.loop.start()