frostfs-testcases/robot/testsuites/integration/acl/acl_extended_deny_replication.robot
anastasia prasolova 3e749abcd0 added keywords library container.py extracted from neofs.py
Signed-off-by: anastasia prasolova <anastasia@nspcc.ru>
2022-04-29 18:17:44 +03:00

63 lines
2.3 KiB
Text

*** Settings ***
Variables common.py
Library container.py
Library neofs.py
Library neofs_verbs.py
Library acl.py
Library payment_neogo.py
Library contract_keywords.py
Library wallet_keywords.py
Library Collections
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 of bytes ${SIMPLE_OBJ_SIZE}
${CID} = Create container ${WALLET} basic_acl=${PUBLIC_ACL} 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