MCPcopy Index your code
hub / github.com/foxcpp/maddy / Dir

Function Dir

internal/testutils/filesystem.go:28–34  ·  view source on GitHub ↗

Dir is a wrapper for os.MkdirTemp that fails the test on errors.

(t *testing.T)

Source from the content-addressed store, hash-verified

26// Dir is a wrapper for os.MkdirTemp that
27// fails the test on errors.
28func Dir(t *testing.T) string {
29 dir, err := os.MkdirTemp("", "maddy-tests-")
30 if err != nil {
31 t.Fatalf("can't create test dir: %v", err)
32 }
33 return dir
34}

Callers 2

TestFSFunction · 0.92
TestSQLFunction · 0.92

Calls

no outgoing calls

Tested by 2

TestFSFunction · 0.74
TestSQLFunction · 0.74