Merged in feature/remove-query (pull request #201)
remove query from codebase part 1 * remove query * fix localstack run
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
package doctextrunner_test
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io"
|
||||
"regexp"
|
||||
"strings"
|
||||
"testing"
|
||||
"time"
|
||||
@@ -14,7 +12,6 @@ import (
|
||||
"queryorchestration/internal/server/runner"
|
||||
"queryorchestration/internal/serviceconfig/aws"
|
||||
"queryorchestration/internal/serviceconfig/objectstore"
|
||||
"queryorchestration/internal/serviceconfig/queue/querysync"
|
||||
"queryorchestration/internal/serviceconfig/textract"
|
||||
"queryorchestration/internal/test"
|
||||
objectstoremock "queryorchestration/mocks/objectstore"
|
||||
@@ -28,10 +25,10 @@ import (
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
// Note: Query sync functionality has been removed. See remove_query_plan.md for details.
|
||||
type DocTextConfig struct {
|
||||
runner.BaseConfig[doctextrunner.Body]
|
||||
aws.AWSConfig
|
||||
querysync.QuerySyncConfig
|
||||
textract.TextractConfig
|
||||
objectstore.ObjectStoreConfig
|
||||
}
|
||||
@@ -42,7 +39,6 @@ func TestDocTextRunner(t *testing.T) {
|
||||
acfg := test.CreateAWSContainer(t, cfg)
|
||||
|
||||
test.SetQueueClient(t, t.Context(), cfg, acfg.ExternalEndpoint)
|
||||
cfg.QuerySyncURL = test.CreateQueue(t, cfg, test.QuerySyncRunnerName)
|
||||
|
||||
mockStore := objectstoremock.NewMockS3Client(t)
|
||||
cfg.StoreClient = mockStore
|
||||
@@ -135,9 +131,8 @@ func TestDocTextRunner(t *testing.T) {
|
||||
doc := doctextrunner.Body{
|
||||
DocumentID: docId,
|
||||
}
|
||||
// Note: Query sync functionality has been removed. Text extraction is now the terminal step.
|
||||
assert.True(t, runner.Process(t.Context(), doc))
|
||||
|
||||
test.AssertMessageBody(t, cfg, cfg.GetQuerySyncURL(), regexp.MustCompile(fmt.Sprintf("{\"id\":\"%s\"}", docId.String())))
|
||||
}
|
||||
|
||||
const pdfHelloWorld = `%PDF-1.4
|
||||
|
||||
Reference in New Issue
Block a user