예제 #1
0
def test_send_pool_config_2_nodes_can_force_writes_false_force_true(
        nodeSet, looper, trustee, trusteeWallet, poolConfigWFFT):
    assert len(nodeSet) == 4

    node1 = nodeSet[2]
    node0 = nodeSet[3]

    checkPoolConfigWritableSet(nodeSet, True)

    disconnect_node_and_ensure_disconnected(looper,
                                            nodeSet,
                                            node0.name,
                                            stopNode=False)
    looper.removeProdable(node0)
    disconnect_node_and_ensure_disconnected(looper,
                                            nodeSet,
                                            node1.name,
                                            stopNode=False)
    looper.removeProdable(node1)

    sendPoolConfig(trustee, trusteeWallet, poolConfigWFFT)

    looper.run(
        eventually(checkPoolConfigWritableSet,
                   nodeSet[0:2],
                   False,
                   retryWait=1,
                   timeout=10))
예제 #2
0
def test_only_trustee_send_pool_config_writes_true_force_false(
        nodeSet, tdir, looper, trustee, trusteeWallet, poolConfigWTFF):
    stClient, stWallet = getClientAddedWithRole(nodeSet, tdir, looper, trustee,
                                                trusteeWallet, 'tmpname',
                                                STEWARD)
    _, req = sendPoolConfig(stClient, stWallet, poolConfigWTFF)
    looper.run(eventually(checkRejects, stClient, req.reqId, 'cannot do'))
def test_only_trustee_send_pool_config_writes_true_force_false(
        nodeSet, tdirWithClientPoolTxns, looper, trustee, trusteeWallet, poolConfigWTFF):
    stClient, stWallet = getClientAddedWithRole(
        nodeSet, tdirWithClientPoolTxns, looper, trustee, trusteeWallet, 'tmpname', STEWARD)
    _, req = sendPoolConfig(stClient, stWallet, poolConfigWTFF)
    looper.run(eventually(checkRejects, stClient, req.reqId, 'cannot do'))