personal memory agent
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

audit: harden reflection pdf no-network test

+8 -1
+8 -1
tests/test_app_reflections.py
··· 128 128 ) 129 129 client = _make_client(journal_copy) 130 130 131 - with patch("apps.reflections.routes.default_url_fetcher") as mock_fetcher: 131 + with ( 132 + patch( 133 + "urllib.request.urlopen", 134 + side_effect=AssertionError("network disabled during reflection pdf render"), 135 + ), 136 + patch("apps.reflections.routes.default_url_fetcher") as mock_fetcher, 137 + ): 132 138 response = client.get("/app/reflections/20260308/pdf") 133 139 134 140 assert response.status_code == 200 135 141 assert response.mimetype == "application/pdf" 142 + assert response.data.startswith(b"%PDF") 136 143 mock_fetcher.assert_not_called() 137 144 138 145