def testTrustAnchorSuspensionByTrustee( looper, sdk_pool_handle, another_trustee, another_trust_anchor): _, did_ta = another_trust_anchor sdk_suspend_role(looper, sdk_pool_handle, another_trustee, did_ta) with pytest.raises(RequestRejectedException): sdk_add_new_nym(looper, sdk_pool_handle, another_trust_anchor, alias=randomString())
def testTrusteeSuspendingEndorser(looper, sdk_pool_handle, sdk_wallet_trustee, sdk_wallet_endorser): _, did = sdk_wallet_endorser sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) with pytest.raises(RequestRejectedException) as e: sdk_add_new_nym(looper, sdk_pool_handle, sdk_wallet_endorser) e.match('Rule for this action is')
def testTrustAnchorSuspensionByTrustee( looper, sdk_pool_handle, another_trustee, another_trust_anchor): _, did_ta = another_trust_anchor sdk_suspend_role(looper, sdk_pool_handle, another_trustee, did_ta) with pytest.raises(RequestRejectedException): sdk_add_new_nym(looper, sdk_pool_handle, another_trust_anchor, alias=randomString())
def testStewardSuspensionByTrustee(looper, sdk_pool_handle, another_trustee, another_steward): _, did_stew = another_steward sdk_suspend_role(looper, sdk_pool_handle, another_trustee, did_stew) with pytest.raises(RequestRejectedException): sdk_add_new_nym(looper, sdk_pool_handle, another_steward, role=TRUST_ANCHOR_STRING)
def testStewardSuspensionByTrustee(looper, sdk_pool_handle, another_trustee, another_steward): _, did_stew = another_steward sdk_suspend_role(looper, sdk_pool_handle, another_trustee, did_stew) with pytest.raises(RequestRejectedException): sdk_add_new_nym(looper, sdk_pool_handle, another_steward, role=TRUST_ANCHOR_STRING)
def testTrusteeSuspendingSteward(looper, sdk_pool_handle, sdk_wallet_trustee, sdk_wallet_steward): _, did = sdk_wallet_steward sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) with pytest.raises(RequestRejectedException) as e: sdk_add_new_nym(looper, sdk_pool_handle, sdk_wallet_steward) e.match('There is no accepted constraint')
def testTrusteeSuspendingTrustAnchor(looper, sdk_pool_handle, sdk_wallet_trustee, sdk_wallet_trust_anchor): _, did = sdk_wallet_trust_anchor sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) with pytest.raises(RequestRejectedException) as e: sdk_add_new_nym(looper, sdk_pool_handle, sdk_wallet_trust_anchor) e.match('None role cannot add None role')
def testTrusteeSuspensionByTrustee(looper, sdk_pool_handle, sdk_wallet_trustee, another_trustee, another_steward1): # trustee suspension by trustee is succeed _, did = another_trustee sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) # trustee suspension by steward1 is failed _, did = sdk_wallet_trustee with pytest.raises(RequestRejectedException) as e: sdk_suspend_role(looper, sdk_pool_handle, another_steward1, did) e.match('is neither Trustee nor owner of')
def testTrusteeSuspensionByTrustee(looper, sdk_pool_handle, sdk_wallet_trustee, another_trustee, another_steward1): # trustee suspension by trustee is succeed _, did = another_trustee sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) # trustee suspension by steward1 is failed _, did = sdk_wallet_trustee with pytest.raises(RequestRejectedException) as e: sdk_suspend_role(looper, sdk_pool_handle, another_steward1, did) e.match('{} can not do this action'.format(STEWARD_STRING))
def testTrusteeSuspensionByTrustee(looper, sdk_pool_handle, sdk_wallet_trustee, another_trustee, another_steward1): # trustee suspension by trustee is succeed _, did = another_trustee sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) # trustee suspension by steward1 is failed _, did = sdk_wallet_trustee with pytest.raises(RequestRejectedException) as e: sdk_suspend_role(looper, sdk_pool_handle, another_steward1, did) e.match('is neither Trustee nor owner of')
def testTrusteeSuspensionByTrustee(looper, sdk_pool_handle, sdk_wallet_trustee, another_trustee, another_steward1): # trustee suspension by trustee is succeed _, did = another_trustee sdk_suspend_role(looper, sdk_pool_handle, sdk_wallet_trustee, did) # trustee suspension by steward1 is failed _, did = sdk_wallet_trustee with pytest.raises(RequestRejectedException) as e: sdk_suspend_role(looper, sdk_pool_handle, another_steward1, did) e.match("Not enough TRUSTEE signatures")