Merged in feature/docclean (pull request #55)
Doc Clean Structure * outline * isdocclean * placeholder for clean log * versionplustesting * versionplustesting * testspassed
This commit is contained in:
@@ -2,19 +2,22 @@ package documentclean_test
|
||||
|
||||
import (
|
||||
documentclean "queryorchestration/internal/document/clean"
|
||||
"queryorchestration/internal/serviceconfig"
|
||||
"queryorchestration/internal/serviceconfig/objectstore"
|
||||
"queryorchestration/internal/serviceconfig/queue/documenttext"
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
type DocCleanConfig struct {
|
||||
serviceconfig.BaseConfig
|
||||
documenttext.DocTextConfig
|
||||
objectstore.ObjectStoreConfig
|
||||
}
|
||||
|
||||
func TestService(t *testing.T) {
|
||||
svc := documentclean.New()
|
||||
cfg := &DocCleanConfig{}
|
||||
svc := documentclean.New(cfg, nil)
|
||||
assert.NotNil(t, svc)
|
||||
}
|
||||
|
||||
func TestIsValidVersion(t *testing.T) {
|
||||
svc := documentclean.New()
|
||||
|
||||
assert.Nil(t, svc.IsValidVersion(2))
|
||||
assert.Error(t, svc.IsValidVersion(-1))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user