Merge pull request #235 from katlapinka/add-detached-core

Enable try-add method in CAS test-framework API
This commit is contained in:
Michal Rakowski
2019-12-20 09:54:03 +01:00
committed by GitHub
3 changed files with 16 additions and 2 deletions

View File

@@ -73,6 +73,13 @@ def remove_detached(core_device: Device, shortcut: bool = False):
return output
def try_add(core_device: Device, cache_id: int):
output = TestRun.executor.run(script_try_add_cmd(str(cache_id), core_device.system_path))
if output.exit_code != 0:
raise CmdException("Failed to execute try add script command.", output)
return Core(core_device.system_path, cache_id)
def reset_counters(cache_id: int, core_id: int = None, shortcut: bool = False):
_core_id = None if core_id is None else str(core_id)
output = TestRun.executor.run(