(self, args: argparse.Namespace)
| 125 | |
| 126 | class BenchmarkAction(NetworkScriptAction): |
| 127 | def execute(self, args: argparse.Namespace): |
| 128 | module = self.load_script(args.script, args) |
| 129 | module.RUN_CMD._parser = self.parser |
| 130 | |
| 131 | old_path = os.getcwd() |
| 132 | # Execute script in each relevant folder |
| 133 | try: |
| 134 | os.chdir(args.network) |
| 135 | results = module.RUN_CMD.run_benchmark() |
| 136 | finally: |
| 137 | os.chdir(old_path) |
| 138 | |
| 139 | # Output to terminal |
| 140 | print(results) |
| 141 | |
| 142 | return 0 |
| 143 | |
| 144 | def add_args(self, parser: argparse.ArgumentParser): |
| 145 | super().add_args(parser) |
nothing calls this directly
no test coverage detected