Add test for get sent offer by payment hash missing (#1692)

This commit is contained in:
Jonathan Zernik 2021-10-22 21:02:04 -05:00 committed by GitHub
parent 74222b9a62
commit 76e1bd29cc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1260,3 +1260,12 @@ def test_get_sent_offer(squeak_db, inserted_sent_offer_id, sent_offer, payment_h
assert retrieved_sent_offer._replace(
sent_offer_id=None,
) == sent_offer
def test_get_sent_offer_missing(squeak_db, inserted_sent_offer_id):
random_hash = gen_random_hash()
retrieved_sent_offer = squeak_db.get_sent_offer_by_payment_hash(
random_hash,
)
assert retrieved_sent_offer is None