Skip to content

Conversation

laterlaugh
Copy link

TempDir() is a method introduced in Go 1.15 for testing.T. It automatically creates a temporary directory and cleans it up after the test is complete, eliminating the hassle of manually handling errors and cleanup.

More detail about TempDir https://pkg.go.dev/testing#B.TempDir

Signed-off-by: laterlaugh <manziwenzhai@sina.cn>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant