chromium/third_party/blink/web_tests/external/wpt/cors/resources/cache-304.py

def main(request, response):
    match = request.headers.get(b"If-None-Match", None)
    if match is not None and match == b"mybestscript-v1":
        response.status = (304, b"YEP")
        return b""
    response.headers.set(b"Access-Control-Allow-Origin", b"*")
    response.headers.set(b"Cache-Control", b"must-revalidate")
    response.headers.set(b"ETag", b"mybestscript-v1")
    response.headers.set(b"Content-Type", b"text/javascript")
    return b"function hep() { }"