Update test titles for most cases

This commit is contained in:
Andrey Berezin 2023-08-07 12:43:16 +03:00
parent d40e875091
commit e0a9d687f2
26 changed files with 184 additions and 213 deletions

View file

@ -138,7 +138,7 @@ def storage_objects(
@pytest.mark.sanity
@pytest.mark.grpc_api
class TestObjectApi(ClusterTestBase):
@allure.title("Validate object storage policy by native API")
@allure.title("Validate object storage policy by native API for {storage_objects}")
def test_object_storage_policies(
self,
request: FixtureRequest,
@ -172,7 +172,7 @@ class TestObjectApi(ClusterTestBase):
)
assert copies == 2, "Expected 2 copies"
@allure.title("Validate get object native API")
@allure.title("Validate get object native API for {storage_objects}")
def test_get_object_api(
self, request: FixtureRequest, storage_objects: list[StorageObjectInfo]
):
@ -193,7 +193,7 @@ class TestObjectApi(ClusterTestBase):
file_hash = get_file_hash(file_path)
assert storage_object.file_hash == file_hash
@allure.title("Validate head object native API")
@allure.title("Validate head object native API for {storage_objects}")
def test_head_object_api(
self, request: FixtureRequest, storage_objects: list[StorageObjectInfo]
):
@ -222,7 +222,7 @@ class TestObjectApi(ClusterTestBase):
)
self.check_header_is_presented(head_info, storage_object_2.attributes)
@allure.title("Validate object search by native API")
@allure.title("Validate object search by native API for {storage_objects}")
def test_search_object_api(
self, request: FixtureRequest, storage_objects: list[StorageObjectInfo]
):
@ -266,21 +266,18 @@ class TestObjectApi(ClusterTestBase):
)
assert sorted(expected_oids) == sorted(result)
@allure.title("Validate object search with removed items")
@allure.title("Validate object search with removed items for {object_size}")
@pytest.mark.parametrize(
"object_size",
[pytest.lazy_fixture("simple_object_size"), pytest.lazy_fixture("complex_object_size")],
ids=["simple object size", "complex object size"],
)
def test_object_search_should_return_tombstone_items(
self, default_wallet: str, request: FixtureRequest, object_size: ObjectSize
self, default_wallet: str, object_size: ObjectSize
):
"""
Validate object search with removed items
"""
allure.dynamic.title(
f"Validate object search with removed items for {request.node.callspec.id}"
)
wallet = default_wallet
cid = create_container(wallet, self.shell, self.cluster.default_rpc_endpoint)
@ -339,7 +336,7 @@ class TestObjectApi(ClusterTestBase):
object_type == "TOMBSTONE"
), f"Object wasn't deleted properly. Found object {tombstone_oid} with type {object_type}"
@allure.title("Validate native object API get_range_hash")
@allure.title("Validate native get_range_hash object API for {storage_objects}")
@pytest.mark.sanity
@pytest.mark.grpc_api
def test_object_get_range_hash(
@ -378,7 +375,7 @@ class TestObjectApi(ClusterTestBase):
get_file_hash(file_path, range_len, range_start) == range_hash
), f"Expected range hash to match {range_cut} slice of file payload"
@allure.title("Validate native object API get_range")
@allure.title("Validate native get_range object API for {storage_objects}")
@pytest.mark.sanity
@pytest.mark.grpc_api
def test_object_get_range(
@ -418,7 +415,9 @@ class TestObjectApi(ClusterTestBase):
== range_content
), f"Expected range content to match {range_cut} slice of file payload"
@allure.title("Validate native object API get_range negative cases")
@allure.title(
"[NEGATIVE] Invalid range in get_range native object API should return error for {storage_objects}"
)
@pytest.mark.sanity
@pytest.mark.grpc_api
def test_object_get_range_negatives(
@ -430,7 +429,7 @@ class TestObjectApi(ClusterTestBase):
Validate get_range negative for object by native gRPC API
"""
allure.dynamic.title(
f"Validate native get_range negative object API for {request.node.callspec.id}"
f"[NEGATIVE] Invalid range in get_range native object API should return error for {request.node.callspec.id}"
)
wallet = storage_objects[0].wallet_file_path
@ -475,7 +474,9 @@ class TestObjectApi(ClusterTestBase):
range_cut=range_cut,
)
@allure.title("Validate native object API get_range_hash negative cases")
@allure.title(
"[NEGATIVE] Invalid range in get_range_hash native object API should return error for {storage_objects}"
)
def test_object_get_range_hash_negatives(
self,
request: FixtureRequest,
@ -485,7 +486,7 @@ class TestObjectApi(ClusterTestBase):
Validate get_range_hash negative for object by native gRPC API
"""
allure.dynamic.title(
f"Validate native get_range_hash negative object API for {request.node.callspec.id}"
f"[NEGATIVE] Invalid range in get_range_hash native object API should return error for {request.node.callspec.id}"
)
wallet = storage_objects[0].wallet_file_path