From 1ee3ca1bd2acc5c869b3ddbaa6db977b952d343f Mon Sep 17 00:00:00 2001 From: sneak Date: Sat, 3 Oct 2026 12:36:54 +0000 Subject: [PATCH] Download-albums example test no longer depends on the disk's free space (closes #160) The test left freeBelowBytes at its 50 GiB default, so on a disk with under 50 GiB free the content cache's limit fell to zero. Downloading another photo then evicted photo 1's cached original, and the test fetched it a fourth time instead of copying it. Both of its libraries now open with freeBelowBytes: 0. Every other test that opens a library or content cache with the real free space was read; none has a result that depends on it. The 50 GiB default is unchanged. Model: opus-5-5 --- TODO.md | 6 ++++++ test/examples/download-albums.test.ts | 3 +++ 2 files changed, 9 insertions(+) diff --git a/TODO.md b/TODO.md index 2907015..f4ab28f 100644 --- a/TODO.md +++ b/TODO.md @@ -25,6 +25,12 @@ declares one. # Completed Steps +- 2026-10-03: The download-albums example test no longer fails on a disk with + under 50 GiB free (issue 160). It opens its libraries with + `freeBelowBytes: 0`, so the free space of the disk it runs on cannot shrink + the cache, evict the original it cached and add a fetch to the count. No other + test's result depends on that free space. The 50 GiB default is unchanged. + - 2026-10-02: `docker build .` stamps the commit's tag or short commit, not `dev` (issue 154). `script/build` writes the version `script/version` prints into `dist/package.json`: the `VERSION` environment variable or build arg when diff --git a/test/examples/download-albums.test.ts b/test/examples/download-albums.test.ts index ac130a7..f4232cd 100644 --- a/test/examples/download-albums.test.ts +++ b/test/examples/download-albums.test.ts @@ -162,6 +162,9 @@ describe("examples/download-albums.ts", () => { refreshIntervalSeconds: 3600, precacheThumbnails: false, precacheOriginals: false, + // The test counts fetches, so the free space of the disk it + // runs on must not shrink the cache and evict photo 1. + freeBelowBytes: 0, }); const first = await open(); -- 2.54.0