Commit 4f9b23a
fix: close render cache even when reconciler never ran
The reconciler's Stop() method was returning early if the reconciler
was never started (running == false), which meant the render cache
cleanup goroutine was never stopped.
This happened in tests that create reconcilers but never call Run() on
them. When Stop() was called in t.Cleanup(), it would skip closing the
render cache, causing goroutine leaks.
Fix: Move renderCache.Close() to execute before the running check, so
the cleanup goroutine is always stopped regardless of whether the
reconciler was ever started.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>1 parent 85bbae6 commit 4f9b23a
1 file changed
+4
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
268 | 268 | | |
269 | 269 | | |
270 | 270 | | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
271 | 275 | | |
272 | 276 | | |
273 | 277 | | |
| |||
292 | 296 | | |
293 | 297 | | |
294 | 298 | | |
295 | | - | |
296 | | - | |
297 | | - | |
298 | 299 | | |
299 | 300 | | |
300 | 301 | | |
| |||
0 commit comments