Skip to content

Commit

Permalink
increase sleep ffs
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Apr 3, 2024
1 parent 514828b commit 6c4a70c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 27 deletions.
25 changes: 0 additions & 25 deletions tests/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,31 +157,6 @@ def pay_onchain(address: str, sats: int) -> str:
return run_cmd(cmd)


# def clean_database(settings):
# if DB_TYPE == POSTGRES:
# db_url = make_url(settings.lnbits_database_url)

# conn = psycopg2.connect(settings.lnbits_database_url)
# conn.autocommit = True
# with conn.cursor() as cur:
# try:
# cur.execute("DROP DATABASE lnbits_test")
# except psycopg2.errors.InvalidCatalogName:
# pass
# cur.execute("CREATE DATABASE lnbits_test")

# db_url.database = "lnbits_test"
# settings.lnbits_database_url = str(db_url)

# core.db.__init__("database")

# conn.close()
# else:
# # FIXME: do this once mock data is removed from test data folder
# # os.remove(settings.lnbits_data_folder + "/database.sqlite3")
# pass


def pay_if_regtest(bolt11: str):
if is_regtest:
pay_real_invoice(bolt11)
4 changes: 2 additions & 2 deletions tests/test_mint_regtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ async def test_regtest_pending_quote(wallet: Wallet, ledger: Ledger):
quote_id=quote.quote,
)
)
await asyncio.sleep(SLEEP_TIME)
await asyncio.sleep(SLEEP_TIME * 3)
# settle_invoice(preimage=preimage)

# expect that melt quote is still pending
Expand All @@ -67,7 +67,7 @@ async def test_regtest_pending_quote(wallet: Wallet, ledger: Ledger):

# only now settle the invoice
settle_invoice(preimage=preimage)
await asyncio.sleep(SLEEP_TIME)
await asyncio.sleep(SLEEP_TIME * 3)

# expect that proofs are now spent
states = await ledger.check_proofs_state([p.Y for p in send_proofs])
Expand Down

0 comments on commit 6c4a70c

Please sign in to comment.