mirror of
https://github.com/planetmint/planetmint.git
synced 2025-03-30 15:08:31 +00:00
fixed test_update_utxoset
Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com>
This commit is contained in:
parent
ea8ef5395a
commit
a7d8a8e9f5
@ -152,17 +152,17 @@ def test_post_transaction_invalid_mode(b, test_abci_rpc):
|
||||
|
||||
@pytest.mark.bdb
|
||||
def test_update_utxoset(b, signed_create_tx, signed_transfer_tx, db_conn):
|
||||
update_utxoset(b.models.connection, signed_create_tx)
|
||||
b.models.update_utxoset(signed_create_tx.to_dict())
|
||||
utxoset = db_conn.get_space("utxos")
|
||||
assert utxoset.select().rowcount == 1
|
||||
utxo = utxoset.select().data
|
||||
assert utxo[0][1] == signed_create_tx.id
|
||||
assert utxo[0][2] == 0
|
||||
update_utxoset(b.models.connection, signed_transfer_tx)
|
||||
assert utxo[0][5] == signed_create_tx.id
|
||||
assert utxo[0][4] == 0
|
||||
b.models.update_utxoset(signed_transfer_tx.to_dict())
|
||||
assert utxoset.select().rowcount == 1
|
||||
utxo = utxoset.select().data
|
||||
assert utxo[0][1] == signed_transfer_tx.id
|
||||
assert utxo[0][2] == 0
|
||||
assert utxo[0][5] == signed_transfer_tx.id
|
||||
assert utxo[0][4] == 0
|
||||
|
||||
|
||||
@pytest.mark.bdb
|
||||
|
Loading…
x
Reference in New Issue
Block a user