(value, public)
| 142 | |
| 143 | @pytest.mark.parametrize(("value", "public"), [(0, False), (60, True)]) |
| 144 | def test_max_age(value, public): |
| 145 | rv = send_file(txt_path, environ, max_age=value) |
| 146 | rv.close() |
| 147 | assert ("no-cache" in rv.headers["Cache-Control"]) != public |
| 148 | assert rv.cache_control.public == public |
| 149 | assert rv.cache_control.max_age == value |
| 150 | assert rv.expires |
| 151 | assert rv.status_code == 200 |
| 152 | |
| 153 | |
| 154 | def test_etag(): |