diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2025-02-21 00:05:40 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-02-21 00:05:40 +0800 |
commit | 3ee5ee2029529e3b0c600f4ec555b3daca178fbe (patch) | |
tree | 2416bf4425150bccd10db7fef22b7aa23edcf061 /modules/util | |
parent | cd225d7034f905f73319b5a9024f6f9d5b6a01c7 (diff) | |
download | gitea-3ee5ee2029529e3b0c600f4ec555b3daca178fbe.tar.gz gitea-3ee5ee2029529e3b0c600f4ec555b3daca178fbe.zip |
Upgrade golangci-lint to v1.64.5 (#33654)
Use `usetesting` instead of deprecated `tenv`.
1. Follow up #33648
2. Make lint pass and add some comments
Diffstat (limited to 'modules/util')
-rw-r--r-- | modules/util/legacy_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/util/legacy_test.go b/modules/util/legacy_test.go index e732094c29..565fb7f284 100644 --- a/modules/util/legacy_test.go +++ b/modules/util/legacy_test.go @@ -17,7 +17,7 @@ import ( func TestCopyFile(t *testing.T) { testContent := []byte("hello") - tmpDir := os.TempDir() + tmpDir := t.TempDir() now := time.Now() srcFile := fmt.Sprintf("%s/copy-test-%d-src.txt", tmpDir, now.UnixMicro()) dstFile := fmt.Sprintf("%s/copy-test-%d-dst.txt", tmpDir, now.UnixMicro()) |