stocks / tests /api /test_static_cache_headers.py
user
python version
ee446e8
Raw History Blame Contribute Delete
434 Bytes
def test_static_assets_must_revalidate(app_client):
resp = app_client.get("/static/manifest.json")
assert resp.status_code == 200
assert resp.headers.get("cache-control") == "no-cache"
def test_static_bundle_must_revalidate(app_client):
resp = app_client.get("/static/css/at-risk.css")
assert resp.status_code == 200
assert resp.headers.get("cache-control") == "no-cache"
assert resp.headers.get("etag")