feat(Envs): unifies overrides to PDA_DATA and PDA_CONFIG, and sets them to /tmp/ for tests.

This commit is contained in:
Lewis Wynne 2025-12-18 21:50:01 +00:00
parent f79434a8df
commit 7707dfbe86
4 changed files with 18 additions and 5 deletions

View file

@ -34,7 +34,8 @@ import (
var update = flag.Bool("update", false, "update test files with results")
func TestMain(t *testing.T) {
t.Setenv("PDA_DATA_DIR", t.TempDir())
t.Setenv("PDA_DATA", t.TempDir())
t.Setenv("PDA_CONFIG", t.TempDir())
ts, err := cmdtest.Read("testdata")
if err != nil {
t.Fatalf("read testdata: %v", err)