Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Jun 19, 2024
1 parent 9c3f9f7 commit ffe699f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 19 deletions.
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
settings.mint_backend_bolt11_sat = settings.mint_backend_bolt11_sat or "FakeWallet"
settings.fakewallet_brr = True
settings.fakewallet_delay_outgoing_payment = None
settings.fakewallet_delay_incoming_payment = 5
settings.fakewallet_delay_incoming_payment = 1
settings.fakewallet_stochastic_invoice = False
assert (
settings.mint_test_database != settings.mint_database
Expand Down
16 changes: 1 addition & 15 deletions tests/test_wallet_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def test_balance(cli_prefix):
assert result.exit_code == 0


def test_invoice_no_check(mint, cli_prefix):
def test_invoice_return_immediately(mint, cli_prefix):
runner = CliRunner()
result = runner.invoke(
cli,
Expand All @@ -132,20 +132,6 @@ def test_invoice_no_check(mint, cli_prefix):
assert result.exit_code == 0


def test_invoice(mint, cli_prefix):
runner = CliRunner()
result = runner.invoke(
cli,
[*cli_prefix, "invoice", "1000"],
)

assert result.exception is None

wallet = asyncio.run(init_wallet())
assert wallet.available_balance >= 1000
assert result.exit_code == 0


def test_invoice_with_split(mint, cli_prefix):
runner = CliRunner()
result = runner.invoke(
Expand Down
4 changes: 1 addition & 3 deletions tests/test_wallet_subscription.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,8 @@ async def wallet(mint):


@pytest.mark.asyncio
@pytest.mark.skipif(is_fake, reason="only regtest")
async def test_wallet_subscription_mint(wallet: Wallet):
if is_fake:
settings.fakewallet_delay_outgoing_payment = 2

if not wallet.mint_info.supports_nut(WEBSOCKETS_NUT):
pytest.skip("No websocket support")

Expand Down

0 comments on commit ffe699f

Please sign in to comment.