frostfs-testcases/robot/testsuites/integration/acl/acl_extended_deny_replication.robot

61 lines
2.2 KiB
Text
Raw Normal View History

*** Settings ***
Variables common.py
Library container.py
Library neofs.py
Library neofs_verbs.py
Library acl.py
Library contract_keywords.py
Library utility_keywords.py
Resource eacl_tables.robot
Resource common_steps_acl_bearer.robot
Resource payment_operations.robot
Resource setup_teardown.robot
Resource storage.robot
*** Variables ***
${FULL_PLACEMENT_RULE} = REP 4 IN X CBF 1 SELECT 4 FROM * AS X
${EXPECTED_COPIES} = ${4}
${DEPOSIT} = ${30}
*** Test cases ***
eACL Deny Replication Operations
[Documentation] Testcase to validate NeoFS replication with eACL deny rules.
[Tags] ACL Replication
[Timeout] 20 min
[Setup] Setup
${_} ${NODE} ${WIF_STORAGE} = Get control endpoint with wif
${WALLET_STORAGE} ${_} = Prepare Wallet with WIF And Deposit ${WIF_STORAGE}
${WALLET} ${_} ${_} = Prepare Wallet And Deposit
# https://github.com/nspcc-dev/neofs-node/issues/881
${FILE} ${_} = Generate file ${SIMPLE_OBJ_SIZE}
${CID} = Create container ${WALLET} basic_acl=eacl-public-read-write rule=${FULL_PLACEMENT_RULE}
Prepare eACL Role rules ${CID}
${OID} = Put object ${WALLET} ${FILE} ${CID}
Validate storage policy for object ${WALLET} ${EXPECTED_COPIES} ${CID} ${OID}
Set eACL ${WALLET} ${CID} ${EACL_DENY_ALL_USER}
Run Keyword And Expect Error *
... Put object ${WALLET} ${FILE} ${CID}
# Drop object to check replication
Drop object ${NODE} ${WALLET_STORAGE} ${CID} ${OID}
Tick Epoch
# We assume that during one epoch object should be replicated
Wait Until Keyword Succeeds ${NEOFS_EPOCH_TIMEOUT} 1m
... Validate storage policy for object ${WALLET_STORAGE} ${EXPECTED_COPIES} ${CID} ${OID}
[Teardown] Teardown acl_deny_replication