26 lines
497 B
Go
26 lines
497 B
Go
|
package sqlite
|
||
|
|
||
|
import (
|
||
|
"os"
|
||
|
"testing"
|
||
|
|
||
|
"forge.cadoles.com/arcad/edge/pkg/storage/testsuite"
|
||
|
"github.com/pkg/errors"
|
||
|
"gitlab.com/wpetit/goweb/logger"
|
||
|
)
|
||
|
|
||
|
func TestDocumentStore(t *testing.T) {
|
||
|
// t.Parallel()
|
||
|
logger.SetLevel(logger.LevelDebug)
|
||
|
|
||
|
file := "./testdata/documentstore_test.sqlite"
|
||
|
|
||
|
if err := os.Remove(file); err != nil && !errors.Is(err, os.ErrNotExist) {
|
||
|
t.Fatalf("%+v", errors.WithStack(err))
|
||
|
}
|
||
|
|
||
|
store := NewDocumentStore(file)
|
||
|
|
||
|
testsuite.TestDocumentStore(t, store)
|
||
|
}
|