From cc85fa69262b6e937e9d675808ca779d15c6fd85 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Fri, 20 Apr 2018 16:12:20 -0700 Subject: refactor tests around more --- tests/routes.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 tests/routes.py (limited to 'tests/routes.py') diff --git a/tests/routes.py b/tests/routes.py new file mode 100644 index 00000000..47b99e30 --- /dev/null +++ b/tests/routes.py @@ -0,0 +1,20 @@ + +import json +import pytest +import fatcat +import fatcat.sql +import tempfile +from fatcat.models import * +from fixtures import * + + +def test_static_routes(rich_app): + app = rich_app + + for route in ('/health', '/robots.txt', '/', '/about'): + rv = app.get(route) + assert rv.status_code == 200 + + assert app.get("/static/bogus/route").status_code == 404 + + -- cgit v1.2.3