def test_image_is_served_from_frames_root(client, tmp_path): frames_root = tmp_path / "frames" frames_root.mkdir(parents=True, exist_ok=True) (frames_root / "hello.png").write_bytes(b"fake-png-bytes") resp = client.get("/images/hello.png") assert resp.status_code == 200 assert resp.content == b"fake-png-bytes" def test_missing_image_returns_404(client): resp = client.get("/images/does-not-exist.png") assert resp.status_code == 404