This repository has been archived on 2020-09-24. You can view files and clone it, but cannot push or open issues or pull requests.
consumer-api/consumer_api/tests/consumers_view_test.py
marcsello 858e18362f
Some checks failed
continuous-integration/drone/push Build is failing
Added a single assert
2020-05-14 13:55:20 +02:00

23 lines
371 B
Python

import db
import pytest
@pytest.fixture
def client(mocker):
mocker.patch("db.redis_client")
db.redis_client.get.side_effect=lambda a: None
from app import app
app.config['TESTING'] = True
with app.test_client() as client:
yield client
def test_response_length(client):
r = client.get('/consumers')
assert r.status_code == 200