Skip to content

Commit

Permalink
fix test: expect melt quote pending if payment state is unknown
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Jan 4, 2025
1 parent 3f45d9c commit 5c8ab19
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/test_mint_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,18 +452,19 @@ async def test_startup_regtest_pending_quote_unknown(wallet: Wallet, ledger: Led

await asyncio.sleep(SLEEP_TIME)

# run startup routinge
# run startup routine
await ledger.startup_ledger()

# expect that no melt quote is pending
# expect that melt quote is still pending
melt_quotes = await ledger.crud.get_all_melt_quotes_from_pending_proofs(
db=ledger.db
)
assert not melt_quotes
assert melt_quotes
assert melt_quotes[0].state == MeltQuoteState.pending

# expect that proofs are unspent
# expect that proofs are pending
states = await ledger.db_read.get_proofs_states([p.Y for p in send_proofs])
assert all([s.unspent for s in states])
assert all([s.pending for s in states])

# clean up
cancel_invoice(preimage_hash=preimage_hash)

0 comments on commit 5c8ab19

Please sign in to comment.