DashboardcraftfindConfigFile _configPathCache temp te…

findConfigFile _configPathCache temp tests

Category: gotcha
Confidence: 1.00
ID: 01a06916-ade5-7a64-a9de-80da6d3aa69d
Project ID: e16af391-c497-4837-b681-c849a5514499
Cross-project: No
Recalled in other projects: 0
Source session: 1Okgn0vvN7hdZmhlc
Created: 2026-09-03 21:04:49
Updated: 2026-09-03 21:04:49

Content

Trap: changing process.cwd() to a new temporary fixture appears to make getWorkspaceNames() discover its .craft.yml, but findConfigFile() returns the module-level _configPathCache first. A prior fixture cleanup then produces ENOENT for its deleted config, which looks like glob-resolution failure. Fix: reset discovery through the public cache-clearing path between fixture directories; do not test workspace glob behavior against a stale cached config path.

Move to: