Found by the review of #187 (#183). Checked against next at 04093f5.
TestPeriodicReconciliationAdoptsFileThatAppearsAfterStartup in internal/imgcache waits for the evictor's startup pass with a fixed time.Sleep before writing its file. It cannot fail because of that, but on a slow start the startup pass can still be running when the file appears and adopt it, so the test can pass without proving its claim that the periodic pass adopts files that appear after startup.
Plan: wait for the startup pass the way TestEvictionRunsOnPeriodicSchedule now does (hold the test database's only connection until the startup pass is blocked on it, write the file, release), so the file can only be adopted by a periodic pass. No sleep used to wait for the evictor, no assertion weakened. Test-only.
Model: opus-5-5
Found by the review of https://git.eeqj.de/sneak/pixa/pulls/187 (https://git.eeqj.de/sneak/pixa/issues/183). Checked against `next` at `04093f5`.
`TestPeriodicReconciliationAdoptsFileThatAppearsAfterStartup` in `internal/imgcache` waits for the evictor's startup pass with a fixed `time.Sleep` before writing its file. It cannot fail because of that, but on a slow start the startup pass can still be running when the file appears and adopt it, so the test can pass without proving its claim that the periodic pass adopts files that appear after startup.
Plan: wait for the startup pass the way `TestEvictionRunsOnPeriodicSchedule` now does (hold the test database's only connection until the startup pass is blocked on it, write the file, release), so the file can only be adopted by a periodic pass. No sleep used to wait for the evictor, no assertion weakened. Test-only.
Model: opus-5-5
#193 makes the test hold the test database's only connection until the startup pass waits for it, then write the file and let the connection go, so only a periodic pass can adopt the file. Test only, as planned.
Model: opus-5-5
https://git.eeqj.de/sneak/pixa/pulls/193 makes the test hold the test database's only connection until the startup pass waits for it, then write the file and let the connection go, so only a periodic pass can adopt the file. Test only, as planned.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Found by the review of #187 (#183). Checked against
nextat04093f5.TestPeriodicReconciliationAdoptsFileThatAppearsAfterStartupininternal/imgcachewaits for the evictor's startup pass with a fixedtime.Sleepbefore writing its file. It cannot fail because of that, but on a slow start the startup pass can still be running when the file appears and adopt it, so the test can pass without proving its claim that the periodic pass adopts files that appear after startup.Plan: wait for the startup pass the way
TestEvictionRunsOnPeriodicSchedulenow does (hold the test database's only connection until the startup pass is blocked on it, write the file, release), so the file can only be adopted by a periodic pass. No sleep used to wait for the evictor, no assertion weakened. Test-only.Model: opus-5-5
#193 makes the test hold the test database's only connection until the startup pass waits for it, then write the file and let the connection go, so only a periodic pass can adopt the file. Test only, as planned.
Model: opus-5-5