mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-21 21:27:13 +00:00
test: use memory for integration and journal for migration
This commit is contained in:
parent
24028747d3
commit
aea3c7d6e8
|
@ -4,7 +4,8 @@ RUN_MODE = prod
|
|||
|
||||
[database]
|
||||
DB_TYPE = sqlite3
|
||||
PATH = :memory:
|
||||
PATH = tests/{{TEST_TYPE}}/gitea-{{TEST_TYPE}}-sqlite/gitea.db
|
||||
SQLITE_JOURNAL_MODE = MEMORY
|
||||
|
||||
[indexer]
|
||||
REPO_INDEXER_ENABLED = true
|
||||
|
|
|
@ -175,6 +175,9 @@ func InitTest(requireGitea bool) {
|
|||
log.Fatal("db.Exec: CREATE SCHEMA: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
case setting.Database.Type.IsSQLite3():
|
||||
setting.Database.Path = ":memory:"
|
||||
}
|
||||
|
||||
routers.InitWebInstalled(graceful.GetManager().HammerContext())
|
||||
|
|
Loading…
Reference in a new issue