userver: samples/hello_service/tests/test_hello.py
Loading...
Searching...
No Matches
samples/hello_service/tests/test_hello.py
1# /// [Functional test]
2async def test_ping(service_client):
3 response = await service_client.get('/hello')
4 assert response.status == 200
5 assert response.content == b'Hello world!\n'
6 # /// [Functional test]
7
8
9async def test_wrong_method(service_client):
10 response = await service_client.request('KEK', '/hello')
11 assert response.status == 400
12 assert response.content == b'bad request'