forked from TrueCloudLab/frostfs-testcases
Bump neofs-testlib version 0.3.0 -> 0.4.0
Signed-off-by: Vladimir Avdeev <v.avdeev@yadro.com>
This commit is contained in:
parent
14a4d014d1
commit
bf2f638618
11 changed files with 19 additions and 15 deletions
|
@ -5,7 +5,6 @@ from time import sleep
|
||||||
|
|
||||||
import allure
|
import allure
|
||||||
from neofs_testlib.shell import Shell
|
from neofs_testlib.shell import Shell
|
||||||
|
|
||||||
from remote_process import RemoteProcess
|
from remote_process import RemoteProcess
|
||||||
|
|
||||||
EXIT_RESULT_CODE = 0
|
EXIT_RESULT_CODE = 0
|
||||||
|
|
|
@ -41,9 +41,7 @@ class RemoteProcess:
|
||||||
Returns:
|
Returns:
|
||||||
RemoteProcess instance for further examination
|
RemoteProcess instance for further examination
|
||||||
"""
|
"""
|
||||||
remote_process = cls(
|
remote_process = cls(cmd=command, process_dir=f"/tmp/proc_{uuid.uuid4()}", shell=shell)
|
||||||
cmd=command, process_dir=f"/tmp/proc_{uuid.uuid4()}", shell=shell
|
|
||||||
)
|
|
||||||
remote_process._create_process_dir()
|
remote_process._create_process_dir()
|
||||||
remote_process._generate_command_script(command)
|
remote_process._generate_command_script(command)
|
||||||
remote_process._start_process()
|
remote_process._start_process()
|
||||||
|
|
|
@ -3,11 +3,10 @@ from dataclasses import asdict
|
||||||
|
|
||||||
import allure
|
import allure
|
||||||
from common import STORAGE_NODE_SERVICE_NAME_REGEX
|
from common import STORAGE_NODE_SERVICE_NAME_REGEX
|
||||||
|
from k6 import K6, LoadParams, LoadResults
|
||||||
from neofs_testlib.hosting import Hosting
|
from neofs_testlib.hosting import Hosting
|
||||||
from neofs_testlib.shell import SSHShell
|
from neofs_testlib.shell import SSHShell
|
||||||
|
|
||||||
from k6 import K6, LoadParams, LoadResults
|
|
||||||
|
|
||||||
|
|
||||||
@allure.title("Get services endpoints")
|
@allure.title("Get services endpoints")
|
||||||
def get_services_endpoints(
|
def get_services_endpoints(
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
|
import logging
|
||||||
import os
|
import os
|
||||||
import uuid
|
import uuid
|
||||||
import logging
|
|
||||||
from typing import Optional
|
from typing import Optional
|
||||||
|
|
||||||
import allure
|
import allure
|
||||||
|
|
|
@ -19,6 +19,7 @@ from python_keywords.node_management import node_healthcheck
|
||||||
|
|
||||||
logger = logging.getLogger("NeoLogger")
|
logger = logging.getLogger("NeoLogger")
|
||||||
|
|
||||||
|
|
||||||
def pytest_collection_modifyitems(items):
|
def pytest_collection_modifyitems(items):
|
||||||
# Make network tests last based on @pytest.mark.node_mgmt
|
# Make network tests last based on @pytest.mark.node_mgmt
|
||||||
def priority(item: pytest.Item) -> int:
|
def priority(item: pytest.Item) -> int:
|
||||||
|
@ -27,6 +28,7 @@ def pytest_collection_modifyitems(items):
|
||||||
|
|
||||||
items.sort(key=lambda item: priority(item))
|
items.sort(key=lambda item: priority(item))
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture(scope="session")
|
@pytest.fixture(scope="session")
|
||||||
def configure_testlib():
|
def configure_testlib():
|
||||||
get_reporter().register_handler(AllureHandler())
|
get_reporter().register_handler(AllureHandler())
|
||||||
|
|
|
@ -3,14 +3,12 @@ from enum import Enum
|
||||||
import allure
|
import allure
|
||||||
import pytest
|
import pytest
|
||||||
from common import (
|
from common import (
|
||||||
|
HTTP_GATE_SERVICE_NAME_REGEX,
|
||||||
LOAD_NODE_SSH_PRIVATE_KEY_PATH,
|
LOAD_NODE_SSH_PRIVATE_KEY_PATH,
|
||||||
LOAD_NODE_SSH_USER,
|
LOAD_NODE_SSH_USER,
|
||||||
LOAD_NODES,
|
LOAD_NODES,
|
||||||
STORAGE_NODE_SERVICE_NAME_REGEX,
|
STORAGE_NODE_SERVICE_NAME_REGEX,
|
||||||
HTTP_GATE_SERVICE_NAME_REGEX,
|
|
||||||
)
|
)
|
||||||
from neofs_testlib.hosting import Hosting
|
|
||||||
|
|
||||||
from k6 import LoadParams
|
from k6 import LoadParams
|
||||||
from load import (
|
from load import (
|
||||||
clear_cache_and_data,
|
clear_cache_and_data,
|
||||||
|
@ -18,6 +16,7 @@ from load import (
|
||||||
multi_node_k6_run,
|
multi_node_k6_run,
|
||||||
prepare_k6_instances,
|
prepare_k6_instances,
|
||||||
)
|
)
|
||||||
|
from neofs_testlib.hosting import Hosting
|
||||||
|
|
||||||
|
|
||||||
class LoadTime(Enum):
|
class LoadTime(Enum):
|
||||||
|
|
|
@ -349,7 +349,7 @@ def test_placement_policy_negative(
|
||||||
@pytest.mark.node_mgmt
|
@pytest.mark.node_mgmt
|
||||||
@allure.title("NeoFS object replication on node failover")
|
@allure.title("NeoFS object replication on node failover")
|
||||||
def test_replication(
|
def test_replication(
|
||||||
prepare_wallet_and_deposit, client_shell: Shell, after_run_start_all_nodes, hosting: Hosting
|
prepare_wallet_and_deposit, client_shell: Shell, after_run_start_all_nodes, hosting: Hosting
|
||||||
):
|
):
|
||||||
"""
|
"""
|
||||||
Test checks object replication on storage not failover and come back.
|
Test checks object replication on storage not failover and come back.
|
||||||
|
|
|
@ -5,7 +5,14 @@ import uuid
|
||||||
import allure
|
import allure
|
||||||
import pytest
|
import pytest
|
||||||
import yaml
|
import yaml
|
||||||
from common import ASSETS_DIR, FREE_STORAGE, NEOFS_CLI_EXEC, NEOFS_ENDPOINT, WALLET_CONFIG, WALLET_PASS
|
from common import (
|
||||||
|
ASSETS_DIR,
|
||||||
|
FREE_STORAGE,
|
||||||
|
NEOFS_CLI_EXEC,
|
||||||
|
NEOFS_ENDPOINT,
|
||||||
|
WALLET_CONFIG,
|
||||||
|
WALLET_PASS,
|
||||||
|
)
|
||||||
from neofs_testlib.cli import NeofsCli
|
from neofs_testlib.cli import NeofsCli
|
||||||
from neofs_testlib.utils.wallet import get_last_address_from_wallet, init_wallet
|
from neofs_testlib.utils.wallet import get_last_address_from_wallet, init_wallet
|
||||||
|
|
||||||
|
|
|
@ -8,9 +8,9 @@ import pytest
|
||||||
from common import ASSETS_DIR, COMPLEX_OBJ_SIZE, FREE_STORAGE, SIMPLE_OBJ_SIZE, WALLET_PASS
|
from common import ASSETS_DIR, COMPLEX_OBJ_SIZE, FREE_STORAGE, SIMPLE_OBJ_SIZE, WALLET_PASS
|
||||||
from data_formatters import get_wallet_public_key
|
from data_formatters import get_wallet_public_key
|
||||||
from file_helper import concat_files, generate_file, generate_file_with_content, get_file_hash
|
from file_helper import concat_files, generate_file, generate_file_with_content, get_file_hash
|
||||||
|
from neofs_testlib.utils.wallet import init_wallet
|
||||||
from python_keywords.payment_neogo import deposit_gas, transfer_gas
|
from python_keywords.payment_neogo import deposit_gas, transfer_gas
|
||||||
from s3_helper import assert_object_lock_mode, check_objects_in_bucket, set_bucket_versioning
|
from s3_helper import assert_object_lock_mode, check_objects_in_bucket, set_bucket_versioning
|
||||||
from neofs_testlib.utils.wallet import init_wallet
|
|
||||||
|
|
||||||
from steps import s3_gate_bucket, s3_gate_object
|
from steps import s3_gate_bucket, s3_gate_object
|
||||||
from steps.aws_cli_client import AwsCliClient
|
from steps.aws_cli_client import AwsCliClient
|
||||||
|
|
|
@ -35,7 +35,7 @@ neo-mamba==0.10.0
|
||||||
neo3crypto==0.2.1
|
neo3crypto==0.2.1
|
||||||
neo3vm==0.9.0
|
neo3vm==0.9.0
|
||||||
neo3vm-stubs==0.9.0
|
neo3vm-stubs==0.9.0
|
||||||
neofs-testlib==0.3.0
|
neofs-testlib==0.4.0
|
||||||
netaddr==0.8.0
|
netaddr==0.8.0
|
||||||
orjson==3.6.8
|
orjson==3.6.8
|
||||||
packaging==21.3
|
packaging==21.3
|
||||||
|
|
|
@ -7,9 +7,9 @@ import uuid
|
||||||
import allure
|
import allure
|
||||||
import json_transformers
|
import json_transformers
|
||||||
from common import ASSETS_DIR, NEOFS_CLI_EXEC, NEOFS_ENDPOINT, WALLET_CONFIG
|
from common import ASSETS_DIR, NEOFS_CLI_EXEC, NEOFS_ENDPOINT, WALLET_CONFIG
|
||||||
|
from neo3 import wallet
|
||||||
from neofs_testlib.cli import NeofsCli
|
from neofs_testlib.cli import NeofsCli
|
||||||
from neofs_testlib.shell import Shell
|
from neofs_testlib.shell import Shell
|
||||||
from neo3 import wallet
|
|
||||||
|
|
||||||
logger = logging.getLogger("NeoLogger")
|
logger = logging.getLogger("NeoLogger")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue