mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-17 19:03:42 +01:00
pytest: Fix a test assuming a specific DB order
Postgresql does not guarantee insertion order when querying, so we need to actually go and look for the correct transaction. Signed-off-by: Christian Decker <decker.christian@gmail.com>
This commit is contained in:
parent
1e89937a0a
commit
3482d254e3
@ -676,5 +676,6 @@ def test_fundchannel_listtransaction(node_factory, bitcoind):
|
||||
# next call warned about SQL Accessing a null column
|
||||
# and crashed the daemon for accessing random memory or null
|
||||
txs = l1.rpc.listtransactions()['transactions']
|
||||
assert txs[0]['hash'] == txid
|
||||
assert txs[0]['blockheight'] == 0
|
||||
|
||||
tx = [t for t in txs if t['hash'] == txid][0]
|
||||
assert tx['blockheight'] == 0
|
||||
|
Loading…
Reference in New Issue
Block a user