コード例 #1
0
def test_cache_control():
    res = app.get('/')
    assert 'public' in res.headers['Cache-Control']
    assert 'max-age=3600' in res.headers['Cache-Control']
    assert 'no-cache="Cookies"' in res.headers['Cache-Control']
コード例 #2
0
ファイル: test_hello_world.py プロジェクト: imfht/flaskapps
def test_cache_control():
    res = app.get('/')
    assert res.headers['Cache-Control'] == 'max-age=3600, public, no-cache="Cookies"'
コード例 #3
0
def test_hello_world():
    res = app.get('/')
    assert res.status_int == 200
    assert res.body == 'Hello, world!'.encode('utf-8')
コード例 #4
0
def test_hello_world():
    res = app.get('/')
    assert res.status_int == 200
    assert res.body == 'Hello, world!'