The 33 usage blocks matching your own engine is a useful consistency check. I would add a few independently hand-calculated fixtures too, especially one request containing both five-minute and one-hour writes, plus a read followed by an ordinary uncached suffix.
The max(0, writes - w1h) line also deserves an input-consistency check. If hourly writes exceed total writes, silently clamping the remainder hides malformed telemetry. Recording that case as unresolved would keep the savings report auditable when log formats or provider usage fields change.