Reuse source indexes in registry extraction
This commit is contained in:
@@ -18,7 +18,10 @@ func TestExtractMapsItemsWithOwnedEvidenceAndDeterministicOrder(t *testing.T) {
|
||||
{Name: " Gold Pieces ", SourceRefs: responseSourceRefs(3, 2)},
|
||||
{Name: "Star Compass", SourceRefs: []itemSourceRefResponse{{StartUnitID: 2, EndUnitID: 2}, {StartUnitID: 1, EndUnitID: 1}, {StartUnitID: 1, EndUnitID: 1}}},
|
||||
}}}
|
||||
result, err := runExtraction(context.Background(), newExtractor(t, client), extractionRequest())
|
||||
req := extractionRequest()
|
||||
index := source.NewDocumentIndex(req.Source)
|
||||
req.SourceIndex = &index
|
||||
result, err := runExtraction(context.Background(), newExtractor(t, client), req)
|
||||
if err != nil {
|
||||
t.Fatalf("Extract() error = %v, want nil", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user