aboutsummaryrefslogtreecommitdiffstats
path: root/python/tests/web_routes.py
blob: 026776ee22407f1b3933979e4cb075d125333810 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16

import json
import pytest
from fatcat_openapi_client.rest import ApiException
from fixtures import *


def test_static_routes(app):
    for route in ('/health.json', '/robots.txt', '/', '/about', '/rfc',
            '/static/fatcat.jpg'):
        rv = app.get(route)
        assert rv.status_code == 200

    assert app.get("/search").status_code == 302
    assert app.get("/static/bogus/route").status_code == 404