binctr/vendor/github.com/Microsoft/hcsshim/functional/utilities/tempdir.go
Jess Frazelle 94d1cfbfbf
update vendor
Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
2018-09-25 12:27:46 -04:00

15 lines
290 B
Go

package testutilities
import (
"io/ioutil"
"testing"
)
// CreateTempDir creates a temporary directory
func CreateTempDir(t *testing.T) string {
tempDir, err := ioutil.TempDir("", "test")
if err != nil {
t.Fatalf("failed to create temporary directory: %s", err)
}
return tempDir
}