summaryrefslogtreecommitdiffstats
path: root/models/unit_tests.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/unit_tests.go')
-rw-r--r--models/unit_tests.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/models/unit_tests.go b/models/unit_tests.go
index 7254cbf66b..3299630634 100644
--- a/models/unit_tests.go
+++ b/models/unit_tests.go
@@ -19,7 +19,6 @@ import (
"code.gitea.io/gitea/modules/util"
"github.com/stretchr/testify/assert"
- "github.com/unknwon/com"
"xorm.io/xorm"
"xorm.io/xorm/names"
)
@@ -82,8 +81,8 @@ func MainTest(m *testing.M, pathToGiteaRoot string) {
if err = util.RemoveAll(setting.RepoRootPath); err != nil {
fatalTestError("util.RemoveAll: %v\n", err)
}
- if err = com.CopyDir(filepath.Join(pathToGiteaRoot, "integrations", "gitea-repositories-meta"), setting.RepoRootPath); err != nil {
- fatalTestError("com.CopyDir: %v\n", err)
+ if err = util.CopyDir(filepath.Join(pathToGiteaRoot, "integrations", "gitea-repositories-meta"), setting.RepoRootPath); err != nil {
+ fatalTestError("util.CopyDir: %v\n", err)
}
exitStatus := m.Run()
@@ -126,7 +125,7 @@ func PrepareTestEnv(t testing.TB) {
assert.NoError(t, PrepareTestDatabase())
assert.NoError(t, util.RemoveAll(setting.RepoRootPath))
metaPath := filepath.Join(giteaRoot, "integrations", "gitea-repositories-meta")
- assert.NoError(t, com.CopyDir(metaPath, setting.RepoRootPath))
+ assert.NoError(t, util.CopyDir(metaPath, setting.RepoRootPath))
base.SetupGiteaRoot() // Makes sure GITEA_ROOT is set
}