Merged in feature/doctextstructure (pull request #56)

DocTextRunner Structure

* firstround

* shorttests
This commit is contained in:
Michael McGuinness
2025-02-07 14:15:06 +00:00
parent 90353d8161
commit 24a038ec3d
41 changed files with 929 additions and 55 deletions
+14 -12
View File
@@ -1,24 +1,26 @@
package documenttext_test
import (
"queryorchestration/internal/document"
documenttext "queryorchestration/internal/document/text"
"queryorchestration/internal/serviceconfig"
"queryorchestration/internal/serviceconfig/objectstore"
"queryorchestration/internal/serviceconfig/queue/querysync"
"testing"
"github.com/google/uuid"
"github.com/stretchr/testify/assert"
)
type DocTextConfig struct {
serviceconfig.BaseConfig
objectstore.ObjectStoreConfig
querysync.QuerySyncConfig
}
func TestService(t *testing.T) {
svc := documenttext.New()
cfg := &DocTextConfig{}
svc := documenttext.New(cfg, &documenttext.Services{
Document: document.New(cfg),
})
assert.NotNil(t, svc)
}
func TestIsExtracted(t *testing.T) {
svc := documenttext.New()
assert.Nil(t, svc.IsExtracted(&documenttext.IsExtractedParams{
DocumentID: uuid.New(),
MinCleanVersion: int32(1),
MinTextVersion: int32(1),
}))
}