def test_main(self): sys.argv = [sys.argv[0], '-s', 'foo'] try: beat_bin.main() self.assertTrue(MockBeat.running) finally: MockBeat.running = False
def test_main(self): sys.argv = [sys.argv[0], '-s', 'foo'] beat_bin.main(app=self.app) self.Beat().run.assert_called_with()