Fixed ACL import ; made "Verify Split Chain" work

Signed-off-by: anastasia prasolova <anastasia@nspcc.ru>
This commit is contained in:
anastasia prasolova 2021-09-20 17:17:15 +03:00 committed by Anastasia Prasolova
parent ced05475d2
commit 7db9f15633
5 changed files with 34 additions and 20 deletions

View file

@ -287,10 +287,15 @@ def verify_split_chain(private_key: str, cid: str, oid: str):
# Recursive chain validation up to the first object # Recursive chain validation up to the first object
final_verif_data = _verify_child_link(private_key, cid, oid, header_last_parsed, final_verif_data) final_verif_data = _verify_child_link(private_key, cid, oid, header_last_parsed, final_verif_data)
break break
logger.info(f"Found Split Object with header:\n\t{parsed_header_virtual}")
logger.info("Continue to search Last Split Object")
except RuntimeError as e:
logger.info(f"Failed while collectiong Split Objects: {e}")
continue
except:
if marker_last_obj == 0: if marker_last_obj == 0:
raise Exception("Latest object has not been found.") raise Exception("Last object has not been found")
# Get Linking object # Get Linking object
logger.info("Compare Split objects result information with Linking object.") logger.info("Compare Split objects result information with Linking object.")
@ -333,9 +338,14 @@ def verify_split_chain(private_key: str, cid: str, oid: str):
f"is not equal to expected ({final_verif_data['Split ID']})") f"is not equal to expected ({final_verif_data['Split ID']})")
break break
except: logger.info(f"Found Linking Object with header:\n\t{parsed_header_virtual}")
logger.info("Continue to search Linking Object")
except RuntimeError as e:
logger.info(f"Failed while collecting Split Object: {e}")
continue
if marker_link_obj == 0: if marker_link_obj == 0:
raise Exception("Linked object has not been found.") raise Exception("Linked object has not been found")
logger.info("Compare Split objects result information with Virtual object.") logger.info("Compare Split objects result information with Virtual object.")
@ -820,7 +830,7 @@ def get_object(private_key: str, cid: str, oid: str, bearer_token: str,
file_path = f"{ASSETS_DIR}/{write_object}" file_path = f"{ASSETS_DIR}/{write_object}"
logger.info("Going to put the object") logger.info("Going to get the object")
if not endpoint: if not endpoint:
endpoint = random.sample(_get_storage_nodes(), 1)[0] endpoint = random.sample(_get_storage_nodes(), 1)[0]

View file

@ -2,8 +2,9 @@
Variables ../../../variables/common.py Variables ../../../variables/common.py
Library Collections Library Collections
Library ../${RESOURCES}/neofs.py Library neofs.py
Library ../${RESOURCES}/payment_neogo.py Library payment_neogo.py
Library acl.py
Resource common_steps_acl_extended.robot Resource common_steps_acl_extended.robot
Resource ../${RESOURCES}/payment_operations.robot Resource ../${RESOURCES}/payment_operations.robot

View file

@ -2,8 +2,9 @@
Variables ../../../variables/common.py Variables ../../../variables/common.py
Library Collections Library Collections
Library ../${RESOURCES}/neofs.py Library neofs.py
Library ../${RESOURCES}/payment_neogo.py Library payment_neogo.py
Library acl.py
Resource common_steps_acl_extended.robot Resource common_steps_acl_extended.robot
Resource ../${RESOURCES}/payment_operations.robot Resource ../${RESOURCES}/payment_operations.robot

View file

@ -1,8 +1,9 @@
*** Settings *** *** Settings ***
Variables ../../../variables/common.py Variables ../../../variables/common.py
Library Collections Library Collections
Library ../${RESOURCES}/neofs.py Library neofs.py
Library ../${RESOURCES}/payment_neogo.py Library payment_neogo.py
Library acl.py
Resource common_steps_acl_extended.robot Resource common_steps_acl_extended.robot
Resource ../${RESOURCES}/payment_operations.robot Resource ../${RESOURCES}/payment_operations.robot

View file

@ -1,8 +1,9 @@
*** Settings *** *** Settings ***
Variables ../../../variables/common.py Variables ../../../variables/common.py
Library Collections Library Collections
Library ../${RESOURCES}/neofs.py Library neofs.py
Library ../${RESOURCES}/payment_neogo.py Library payment_neogo.py
Library acl.py
Resource common_steps_acl_extended.robot Resource common_steps_acl_extended.robot
Resource ../${RESOURCES}/payment_operations.robot Resource ../${RESOURCES}/payment_operations.robot