Documentation
¶
Overview ¶
Package configtest isolates the CLI's on-disk config so a test never reads or writes the developer's real one.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Isolate ¶
Isolate points the CLI's config at a fresh file under t.TempDir() for the duration of t, and returns that path.
It sets OPENFGA_CONFIG rather than XDG_CONFIG_HOME because only the former is honored on every platform: on macOS the default config lives under ~/Library/Application Support and XDG_CONFIG_HOME is ignored entirely, so a test that relies on it silently falls through to the real config — and the TUI writes config on exit.
It also clears the agent-mode variables (see agentmode.EnvVars).
Types ¶
This section is empty.