sarafu-vise/testutil/fsdb.go
2025-01-21 15:43:26 +00:00

26 lines
398 B
Go

//go:build testfsdb
// +build testfsdb
package testutil
import (
"os"
)
const (
testDbCookie = true
)
func init() {
stateDir, err := os.MkdirTemp("", "sarafu-vise-menutraversal-fs-state-")
if err != nil {
panic(err)
}
override.StateConn = &stateDir
userDir, err := os.MkdirTemp("", "sarafu-vise-menutraversal-fs-user-")
if err != nil {
panic(err)
}
override.UserConn = &userDir
}