Move linux command and wait method to common tools
Signed-off-by: Katarzyna Treder <katarzyna.treder@h-partners.com>
This commit is contained in:
parent
cde7a3af16
commit
4dca1c3c00
@ -16,7 +16,8 @@ from api.cas.statistics import CoreStats, CoreIoClassStats
|
|||||||
from core.test_run_utils import TestRun
|
from core.test_run_utils import TestRun
|
||||||
from storage_devices.device import Device
|
from storage_devices.device import Device
|
||||||
from test_tools import fs_utils, disk_utils
|
from test_tools import fs_utils, disk_utils
|
||||||
from test_utils.os_utils import wait, sync
|
from test_utils.os_utils import sync
|
||||||
|
from test_tools.common.wait import wait
|
||||||
from types.size import Unit, Size
|
from types.size import Unit, Size
|
||||||
|
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@ from datetime import timedelta
|
|||||||
import paramiko
|
import paramiko
|
||||||
|
|
||||||
from core.test_run import TestRun
|
from core.test_run import TestRun
|
||||||
from test_utils.os_utils import wait
|
from test_tools.common.wait import wait
|
||||||
|
|
||||||
|
|
||||||
def check_progress_bar(command: str, progress_bar_expected: bool = True):
|
def check_progress_bar(command: str, progress_bar_expected: bool = True):
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit f60e90192e61b2f4a9864283de76f31d7b397393
|
Subproject commit a954e47b33de846810bb6d74d14bc3a3a23c1901
|
@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
from datetime import timedelta
|
from datetime import timedelta
|
||||||
|
|
||||||
|
import test_tools.common.wait
|
||||||
from core.test_run import TestRun
|
from core.test_run import TestRun
|
||||||
from test_tools import fs_utils
|
from test_tools import fs_utils
|
||||||
from test_tools.dd import Dd
|
from test_tools.dd import Dd
|
||||||
@ -47,7 +48,7 @@ def power_cycle_dut(wait_for_flush_begin=False, core_device=None):
|
|||||||
raise Exception("Core device is None.")
|
raise Exception("Core device is None.")
|
||||||
TestRun.LOGGER.info("Waiting for flushing to begin...")
|
TestRun.LOGGER.info("Waiting for flushing to begin...")
|
||||||
core_writes_before = core_device.get_io_stats().sectors_written
|
core_writes_before = core_device.get_io_stats().sectors_written
|
||||||
os_utils.wait(lambda: core_writes_before < core_device.get_io_stats().sectors_written,
|
test_tools.common.wait.wait(lambda: core_writes_before < core_device.get_io_stats().sectors_written,
|
||||||
timedelta(minutes=3),
|
timedelta(minutes=3),
|
||||||
timedelta(milliseconds=100))
|
timedelta(milliseconds=100))
|
||||||
power_control = TestRun.plugin_manager.get_plugin('power_control')
|
power_control = TestRun.plugin_manager.get_plugin('power_control')
|
||||||
|
@ -17,8 +17,8 @@ from test_utils.os_utils import (
|
|||||||
set_wbt_lat,
|
set_wbt_lat,
|
||||||
get_wbt_lat,
|
get_wbt_lat,
|
||||||
get_dut_cpu_number,
|
get_dut_cpu_number,
|
||||||
wait,
|
|
||||||
)
|
)
|
||||||
|
from test_tools.common.wait import wait
|
||||||
from api.cas import casadm
|
from api.cas import casadm
|
||||||
from api.cas.cache_config import (
|
from api.cas.cache_config import (
|
||||||
CacheMode,
|
CacheMode,
|
||||||
|
Loading…
Reference in New Issue
Block a user