Cache headers are a contract with two clocks
Separate browser freshness from origin validation, then verify the response headers that implement both.
Separate browser freshness from origin validation, then verify the response headers that implement both.
Test compressed and uncompressed requests separately so caches and validators describe the bytes actually served.
Check the method, Location header, and cache behavior before choosing a redirect or an error status.