mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-05-06 19:40:42 -05:00
set backend to disk in tests
This commit is contained in:
@@ -80,6 +80,7 @@ func init() {
|
||||
)
|
||||
|
||||
cfg := config.New()
|
||||
cfg.Repo.Backend = "disk"
|
||||
cfg.Repo.Disk.Path = dataPath
|
||||
cfg.Server.DemoUsersAndGroups = true
|
||||
var hdlr *svc.Service
|
||||
|
||||
@@ -33,6 +33,7 @@ var (
|
||||
func init() {
|
||||
cfg := config.New()
|
||||
cfg.Server.Name = "accounts"
|
||||
cfg.Repo.Backend = "disk"
|
||||
cfg.Repo.Disk.Path = dataPath
|
||||
logger := olog.NewLogger(olog.Color(true), olog.Pretty(true))
|
||||
roleServiceMock = buildRoleServiceMock()
|
||||
|
||||
@@ -83,6 +83,7 @@ func getNonUniqueIdxSut(t *testing.T, entity interface{}, indexBy string) (index
|
||||
dataPath, _ := WriteIndexTestData(Data, "ID", "")
|
||||
cfg := config.Config{
|
||||
Repo: config.Repo{
|
||||
Backend: "disk",
|
||||
Disk: config.Disk{
|
||||
Path: dataPath,
|
||||
},
|
||||
|
||||
@@ -103,6 +103,7 @@ func getUniqueIdxSut(t *testing.T, indexBy string, entityType interface{}) (inde
|
||||
dataPath, _ := WriteIndexTestData(Data, "ID", "")
|
||||
cfg := config.Config{
|
||||
Repo: config.Repo{
|
||||
Backend: "disk",
|
||||
Disk: config.Disk{
|
||||
Path: dataPath,
|
||||
},
|
||||
|
||||
@@ -300,6 +300,7 @@ func TestQueryDiskImpl(t *testing.T) {
|
||||
func createDiskIndexer(dataDir string) *Indexer {
|
||||
return CreateIndexer(&config.Config{
|
||||
Repo: config.Repo{
|
||||
Backend: "disk",
|
||||
Disk: config.Disk{
|
||||
Path: dataDir,
|
||||
},
|
||||
|
||||
@@ -542,6 +542,7 @@ func init() {
|
||||
DemoUsersAndGroups: true,
|
||||
},
|
||||
Repo: accountsCfg.Repo{
|
||||
Backend: "disk",
|
||||
Disk: accountsCfg.Disk{
|
||||
Path: dataPath,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user