Documentation
¶
Overview ¶
Package testhome keeps a package's tests off the developer's machine.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Main ¶
Main runs m with $HOME and the XDG base directories pointed at a fresh temp directory, so no test reads or writes the real ~/.config/ask or ~/.claude — or the developer's config steers a test at a real model — by accident. A test that needs a home of its own still sets one with t.Setenv. env adds further variables for the whole run, as key, value pairs.
func NoClaude ¶
func NoClaude() []string
NoClaude is the env pair that points the Claude Code provider at a binary that does not exist, so a test that reaches it (a model listing over the real registry) fails fast instead of starting the real CLI.
func UseRealHome ¶
UseRealHome points $HOME back at the developer's own for one test. Only opt-in tests that deliberately drive real tools use it — the claude CLI finds its login there.
Types ¶
This section is empty.