aboutsummaryrefslogtreecommitdiffstats
path: root/models/migrations
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2022-04-02 00:34:57 +0800
committerGitHub <noreply@github.com>2022-04-02 00:34:57 +0800
commit4f27c289472a4cfafb5a9b0e38e6a3413c30c562 (patch)
tree4a9388cfaf2efe4e9d0ed0242736769ef7e3e083 /models/migrations
parent4c5cb1e2f2c7a1fcc3b151192bd45bd1bbc090bd (diff)
downloadgitea-4f27c289472a4cfafb5a9b0e38e6a3413c30c562.tar.gz
gitea-4f27c289472a4cfafb5a9b0e38e6a3413c30c562.zip
Remove legacy `unknwon/com` package (#19298)
Follows: #19284 * The `CopyDir` is only used inside test code * Rewrite `ToSnakeCase` with more test cases * The `RedisCacher` only put strings into cache, here we use internal `toStr` to replace the legacy `ToStr` * The `UniqueQueue` can use string as ID directly, no need to call `ToStr`
Diffstat (limited to 'models/migrations')
-rw-r--r--models/migrations/migrations_test.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/migrations/migrations_test.go b/models/migrations/migrations_test.go
index a17eba54e8..a1fd49a8b9 100644
--- a/models/migrations/migrations_test.go
+++ b/models/migrations/migrations_test.go
@@ -203,7 +203,7 @@ func prepareTestEnv(t *testing.T, skip int, syncModels ...interface{}) (*xorm.En
deferFn := PrintCurrentTest(t, ourSkip)
assert.NoError(t, os.RemoveAll(setting.RepoRootPath))
- assert.NoError(t, util.CopyDir(path.Join(filepath.Dir(setting.AppPath), "integrations/gitea-repositories-meta"),
+ assert.NoError(t, unittest.CopyDir(path.Join(filepath.Dir(setting.AppPath), "integrations/gitea-repositories-meta"),
setting.RepoRootPath))
ownerDirs, err := os.ReadDir(setting.RepoRootPath)
if err != nil {