pomerium/internal/fileutil
Eng Zer Jun 45ce6f693a
test: use T.TempDir to create temporary test directory (#3725)
Prior to this commit, temporary directories in tests were created using
`filepath.Join` and `os.MkdirAll`.

This commit replaces `os.MkdirAll` with `t.TempDir` in tests. The
directory created by `t.TempDir` is automatically removed when the test
and all its subtests complete.

Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2022-11-08 09:16:32 -07:00
..
fileutil.go *: remove import path comments (#545) 2020-03-16 10:13:47 -07:00
fileutil_test.go dev: update linter (#1728) 2020-12-30 09:02:57 -08:00
watcher.go fileutil: update watcher to use fsnotify and polling (#3663) 2022-10-19 09:13:08 -06:00
watcher_test.go test: use T.TempDir to create temporary test directory (#3725) 2022-11-08 09:16:32 -07:00