mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-20 12:33:09 -06:00
Fix test
This commit is contained in:
parent
aae06b80f6
commit
1b955fa1fa
|
|
@ -18,16 +18,20 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/matrix-org/dendrite/internal/fulltext"
|
|
||||||
"github.com/matrix-org/dendrite/setup/config"
|
|
||||||
"github.com/matrix-org/gomatrixserverlib"
|
"github.com/matrix-org/gomatrixserverlib"
|
||||||
"github.com/matrix-org/util"
|
"github.com/matrix-org/util"
|
||||||
|
|
||||||
|
"github.com/matrix-org/dendrite/internal/fulltext"
|
||||||
|
"github.com/matrix-org/dendrite/setup/config"
|
||||||
)
|
)
|
||||||
|
|
||||||
func mustOpenIndex(t *testing.T, tempDir string) *fulltext.Search {
|
func mustOpenIndex(t *testing.T, tempDir string) *fulltext.Search {
|
||||||
t.Helper()
|
t.Helper()
|
||||||
cfg := config.Fulltext{}
|
cfg := config.Fulltext{}
|
||||||
cfg.Defaults(true)
|
cfg.Defaults(config.DefaultOpts{
|
||||||
|
Generate: true,
|
||||||
|
Monolithic: true,
|
||||||
|
})
|
||||||
if tempDir != "" {
|
if tempDir != "" {
|
||||||
cfg.IndexPath = config.Path(tempDir)
|
cfg.IndexPath = config.Path(tempDir)
|
||||||
cfg.InMemory = false
|
cfg.InMemory = false
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue