chore: update to latest pytest (#2800)
This commit is contained in:
parent
8ff4962e86
commit
291c69e470
27 changed files with 303 additions and 310 deletions
|
|
@ -47,7 +47,7 @@ def outbound_bolt11():
|
|||
return bolt11
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_environment_variables():
|
||||
if use_real_api:
|
||||
assert "X-API-KEY" in headers, "X-API-KEY is not present in headers"
|
||||
|
|
@ -56,7 +56,7 @@ async def test_environment_variables():
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_get_wallet_id():
|
||||
if use_real_api:
|
||||
wallet_id = await funding_source._init_wallet_id()
|
||||
|
|
@ -66,7 +66,7 @@ async def test_get_wallet_id():
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_status():
|
||||
if use_real_api:
|
||||
status = await funding_source.status()
|
||||
|
|
@ -76,7 +76,7 @@ async def test_status():
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_create_invoice():
|
||||
if use_real_api:
|
||||
invoice_response = await funding_source.create_invoice(amount=1000, memo="test")
|
||||
|
|
@ -107,7 +107,7 @@ async def test_create_invoice():
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_pay_invoice_self_payment():
|
||||
if use_real_api:
|
||||
invoice_response = await funding_source.create_invoice(amount=100, memo="test")
|
||||
|
|
@ -122,7 +122,7 @@ async def test_pay_invoice_self_payment():
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_outbound_invoice_payment(outbound_bolt11):
|
||||
if use_real_api:
|
||||
payment_response = await funding_source.pay_invoice(
|
||||
|
|
@ -138,7 +138,7 @@ async def test_outbound_invoice_payment(outbound_bolt11):
|
|||
assert True, "BLINK_TOKEN is not set. Skipping test using mock api"
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
async def test_get_payment_status(payhash):
|
||||
if use_real_api:
|
||||
payment_status = await funding_source.get_payment_status(payhash)
|
||||
|
|
|
|||
|
|
@ -174,7 +174,7 @@ async def run(data: WalletTest):
|
|||
await nwcwallet.cleanup()
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
@pytest.mark.parametrize(
|
||||
"test_data",
|
||||
wallet_fixtures_from_json("tests/wallets/fixtures/json/fixtures_nwc.json"),
|
||||
|
|
@ -184,7 +184,7 @@ async def test_nwc_wallet(test_data: WalletTest):
|
|||
await run(test_data)
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
@pytest.mark.parametrize(
|
||||
"test_data",
|
||||
wallet_fixtures_from_json("tests/wallets/fixtures/json/fixtures_nwc_bad.json"),
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ def httpserver_listen_address():
|
|||
return ("127.0.0.1", 8555)
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
@pytest.mark.parametrize(
|
||||
"test_data",
|
||||
wallet_fixtures_from_json("tests/wallets/fixtures/json/fixtures_rest.json"),
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ from tests.wallets.helpers import (
|
|||
)
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@pytest.mark.anyio
|
||||
@pytest.mark.parametrize(
|
||||
"test_data",
|
||||
wallet_fixtures_from_json("tests/wallets/fixtures/json/fixtures_rpc.json"),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue