nostrrelay/tests/test_init.py
Vlad Stan 3dc066fbd4
Some checks failed
/ release (push) Has been cancelled
/ pullrequest (push) Has been cancelled
[fix] Ws api tests (#31)
2024-11-11 15:25:25 +02:00

17 lines
381 B
Python

import pytest
from fastapi import APIRouter
from .. import nostrrelay_ext, nostrrelay_start, nostrrelay_stop
# just import router and add it to a test router
@pytest.mark.asyncio
async def test_router():
router = APIRouter()
router.include_router(nostrrelay_ext)
@pytest.mark.asyncio
async def test_start_and_stop():
nostrrelay_start()
await nostrrelay_stop()