Files
Maven/internal/config/helpers_test.go
T
kami d52f60c54e maven: fix test mocks for CalendarEvents interface (verification)
- Add CalendarEvents method to recordingAPI in auth_test.go
- Add CalendarEvents method to fakeCore in handlers_test.go

Co-Authored-By: opencode <opencode@anthropic.com>
2026-07-06 04:20:16 +04:00

21 lines
429 B
Go

package config
import (
"os"
"path/filepath"
"testing"
)
// writeFile is a tiny helper used by the test files; inlined so config_test.go
// stays self-contained without a shared helpers file.
func writeFile(t *testing.T, path, body string) error {
t.Helper()
dir := filepath.Dir(path)
if dir != "" {
if err := os.MkdirAll(dir, 0o700); err != nil {
return err
}
}
return os.WriteFile(path, []byte(body), 0o600)
}