Disk tools and fs tools refactor
Signed-off-by: Katarzyna Treder <katarzyna.treder@h-partners.com>
This commit is contained in:
@@ -7,12 +7,13 @@ import random
|
||||
import re
|
||||
import pytest
|
||||
|
||||
import test_tools.fs_tools
|
||||
from api.cas.cache_config import CacheMode, CacheLineSize, CacheModeTrait
|
||||
from api.cas.casadm import OutputFormat, print_statistics, start_cache
|
||||
from core.test_run import TestRun
|
||||
from storage_devices.disk import DiskType, DiskTypeSet, DiskTypeLowerThan
|
||||
from test_tools.dd import Dd
|
||||
from test_tools.disk_utils import Filesystem
|
||||
from test_tools.fs_tools import Filesystem
|
||||
from type_def.size import Size, Unit
|
||||
|
||||
iterations = 64
|
||||
@@ -45,7 +46,7 @@ def test_output_consistency(cache_line_size, cache_mode, test_object):
|
||||
|
||||
with TestRun.step("Start cache and add core with a filesystem."):
|
||||
cache = start_cache(cache_part, cache_mode, cache_line_size, force=True)
|
||||
core_part.create_filesystem(Filesystem.xfs)
|
||||
test_tools.fs_utils.create_filesystem(Filesystem.xfs)
|
||||
exp_obj = cache.add_core(core_part)
|
||||
|
||||
with TestRun.step("Select object to test."):
|
||||
|
@@ -6,6 +6,7 @@ import random
|
||||
|
||||
import pytest
|
||||
|
||||
import test_tools.fs_tools
|
||||
from api.cas import casadm
|
||||
from api.cas import ioclass_config
|
||||
from api.cas.cache_config import CleaningPolicy, CacheMode, CacheLineSize
|
||||
@@ -24,7 +25,7 @@ from api.cas.statistics import (
|
||||
)
|
||||
from core.test_run import TestRun
|
||||
from storage_devices.disk import DiskType, DiskTypeSet, DiskTypeLowerThan
|
||||
from test_tools.disk_utils import Filesystem
|
||||
from test_tools.fs_tools import Filesystem
|
||||
from test_utils.filesystem.file import File
|
||||
from test_tools.os_tools import sync
|
||||
from test_tools.udev import Udev
|
||||
@@ -310,7 +311,7 @@ def prepare(random_cls, cache_count=1, cores_per_cache=1):
|
||||
cache_devices = cache_device.partitions
|
||||
core_devices = core_device.partitions
|
||||
for core_device in core_devices:
|
||||
core_device.create_filesystem(Filesystem.ext4)
|
||||
test_tools.fs_utils.create_filesystem(Filesystem.ext4)
|
||||
|
||||
Udev.disable()
|
||||
caches, cores = [], []
|
||||
|
Reference in New Issue
Block a user