From: Luke Kenneth Casson Leighton Date: Sat, 25 Sep 2021 17:51:53 +0000 (+0100) Subject: use yield from on StateRunners X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=51058af6db705c0e178224c18220cf267f315e58;p=soc.git use yield from on StateRunners --- diff --git a/src/soc/simple/test/test_runner.py b/src/soc/simple/test/test_runner.py index 0eb33078..ee880352 100644 --- a/src/soc/simple/test/test_runner.py +++ b/src/soc/simple/test/test_runner.py @@ -394,7 +394,7 @@ class TestRunner(FHDLTestCase): # there is a fallback which can be "yielded". if self.run_sim: - simrun.setup_during_test() # TODO, some arguments? + yield from simrun.setup_during_test() # TODO, some arguments? if self.run_hdl: yield from hdlrun.setup_during_test() @@ -410,7 +410,7 @@ class TestRunner(FHDLTestCase): # TODO https://bugs.libre-soc.org/show_bug.cgi?id=686#c73 if self.run_sim: - simrun.prepare_for_test(test) + yield from simrun.prepare_for_test(test) if self.run_hdl: yield from hdlrun.prepare_for_test(test) @@ -501,20 +501,20 @@ class TestRunner(FHDLTestCase): # TODO https://bugs.libre-soc.org/show_bug.cgi?id=686#c73 if self.run_sim: - simrun.end_test() # TODO, some arguments? + yield from simrun.end_test() # TODO, some arguments? if self.run_hdl: yield from hdlrun.end_test() - ###### END OF EVERYTHING (but none needs doing, still call fn) ####### - # StateRunner.cleanup() - # TODO https://bugs.libre-soc.org/show_bug.cgi?id=686#c73 + ###### END OF EVERYTHING (but none needs doing, still call fn) #### + # StateRunner.cleanup() + # TODO https://bugs.libre-soc.org/show_bug.cgi?id=686#c73 - if self.run_sim: - simrun.cleanup() # TODO, some arguments? + if self.run_sim: + yield from simrun.cleanup() # TODO, some arguments? - if self.run_hdl: - hdlrun.cleanup() + if self.run_hdl: + yield from hdlrun.cleanup() styles = { 'dec': {'base': 'dec'},