summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2021-12-07 13:44:08 +0800
committerGitHub <noreply@github.com>2021-12-07 13:44:08 +0800
commita6f961fba416e146f5da6cb18115d2f6251d4fe3 (patch)
tree53f437167ca3720510d29e17081d0eaa1d1a9521 /models
parentb30870ef8bcf98bdf0f0829955fc8599a75e26df (diff)
downloadgitea-a6f961fba416e146f5da6cb18115d2f6251d4fe3.tar.gz
gitea-a6f961fba416e146f5da6cb18115d2f6251d4fe3.zip
Refactor install page (db type) (#17919)
* Refactor install page (db type) * set correct default DB HOST for different DB TYPE * remove legacy TiDB from documents * unify the usage of DB TYPE, in code we only use "mysql". "MySQL" is only shown to users for friendly name. * Gitea can use TiDB via MySQL protocol Co-authored-by: zeripath <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'models')
-rw-r--r--models/engine_test.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/models/engine_test.go b/models/engine_test.go
index 75c854b185..6f4d114db3 100644
--- a/models/engine_test.go
+++ b/models/engine_test.go
@@ -28,8 +28,7 @@ func TestDumpDatabase(t *testing.T) {
}
assert.NoError(t, db.GetEngine(db.DefaultContext).Sync2(new(Version)))
- for _, dbName := range setting.SupportedDatabases {
- dbType := setting.GetDBTypeByName(dbName)
+ for _, dbType := range setting.SupportedDatabaseTypes {
assert.NoError(t, db.DumpDatabase(filepath.Join(dir, dbType+".sql"), dbType))
}
}