larigira/test_web.py
2014-10-27 00:44:55 +01:00

18 lines
333 B
Python

from __future__ import print_function
from gevent import monkey
monkey.patch_all(subprocess=True)
import pytest
from rpc import create_app
@pytest.fixture
def app(queue):
return create_app(queue)
def test_refresh(app):
assert app.queue.empty()
app.test_client().get('/api/refresh')
assert not app.queue.empty()