def test_windowed(self): """Run the windowed environment and schedule test actions.""" environment = NoiseTV() self.app = moire.GUI(runnable=environment, size=(640, 480)) Clock.schedule_once(self.check_run, 1) Clock.schedule_once(self.increase_speed, 1.2) Clock.schedule_once(self.decrease_speed, 2.5) Clock.schedule_once(self.toggle_sysinfo, 1) Clock.schedule_once(self.toggle_sysinfo, 2) Clock.schedule_once(self.stop_app, 3) self.app.run()
def test_illegal(self): """Run the environment without runnable.""" with self.assertRaises(ValueError): self.app = moire.GUI() Clock.schedule_once(self.stop_app, 1) self.app.run()
def test_fullscreen(self): """Run the environment fullscreen.""" environment = NoiseTV() self.app = moire.GUI(runnable=environment) Clock.schedule_once(self.stop_app, 1) self.app.run()
def main(): """Run model/experiment interactively.""" import moire model = GameOfLifeColor(GOLExperimentColor) gui = moire.GUI(runnable=model) gui.run()
def main(): """Run the whole environment with Moire.""" environment = NoiseTV() gui = moire.GUI(runnable=environment) gui.run()
def run_simulation(model, experiment): """Run model/experiment interactively.""" import moire mod = model(experiment) gui = moire.GUI(runnable=mod) gui.run()