summaryrefslogtreecommitdiffstats
path: root/python/tests/routes.py
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2018-05-28 13:22:41 -0700
committerBryan Newbold <bnewbold@robocracy.org>2018-05-28 13:22:41 -0700
commitc5bd3231df17fda2130e3bd51188dbe34628321a (patch)
tree10adab8b356ec82308240379085483aff94e226e /python/tests/routes.py
parentaf542d66d884bd17daa6f40f3556aa4189b23b36 (diff)
downloadfatcat-c5bd3231df17fda2130e3bd51188dbe34628321a.tar.gz
fatcat-c5bd3231df17fda2130e3bd51188dbe34628321a.zip
start refactoring pythong code
Diffstat (limited to 'python/tests/routes.py')
-rw-r--r--python/tests/routes.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/python/tests/routes.py b/python/tests/routes.py
index 79d97fe4..80eb15fe 100644
--- a/python/tests/routes.py
+++ b/python/tests/routes.py
@@ -3,14 +3,10 @@ import json
import tempfile
import pytest
import fatcat
-import fatcat.sql
-from fatcat.models import *
from fixtures import *
-def test_static_routes(rich_app):
- app = rich_app
-
+def test_static_routes(app):
for route in ('/health', '/robots.txt', '/', '/about'):
rv = app.get(route)
assert rv.status_code == 200
@@ -18,9 +14,7 @@ def test_static_routes(rich_app):
assert app.get("/static/bogus/route").status_code == 404
-def test_all_views(rich_app):
- app = rich_app
-
+def test_all_views(app):
for route in ('work', 'release', 'creator', 'container', 'file'):
print(route)
rv = app.get('/{}/1'.format(route))