25 references to Sources
Microsoft.Extensions.Documents.Abstractions.Tests (25)
DocumentReferencesTests.cs (2)
368
cell.
Sources
.Add(null!);
370
Assert.Null(Assert.Single(cell.
Sources
));
DocumentReviewFollowUpTests.cs (3)
24
Assert.IsType<List<ExtractionDocumentSourceReference>>(new ExtractionDocumentTableCell().
Sources
);
159
cell.
Sources
.Add(reference);
172
cell.
Sources
.Clear();
DocumentTableCellCollectionTests.cs (5)
164
cell.
Sources
.Add(cellSource);
213
Assert.Same(cellSource, Assert.Single(cell.
Sources
));
509
oldAnchor.
Sources
.Add(new ExtractionDocumentSourceReference(frame, DocumentAnnotationTestData.Polygon()));
583
Assert.Same(frame, oldAnchor.
Sources
[0].Page);
584
Assert.Equal(DocumentAnnotationTestData.Polygon(), oldAnchor.
Sources
[0].Polygon);
DocumentTableCellTests.cs (7)
121
empty.
Sources
.Add(new ExtractionDocumentSourceReference(page, DocumentAnnotationTestData.Polygon()));
134
Assert.Equal(DocumentAnnotationTestData.Polygon(), empty.
Sources
[0].Polygon);
136
empty.
Sources
.Add(new ExtractionDocumentSourceReference(page));
137
Assert.Equal(2, empty.
Sources
.Count);
166
empty.
Sources
.Add(new ExtractionDocumentSourceReference(pdf, DocumentAnnotationTestData.Polygon()));
167
empty.
Sources
.Add(new ExtractionDocumentSourceReference(raster, rasterPolygon));
193
var sources = table.Cells.GetCoveringCell(0, 1)!.
Sources
;
DocumentTableElementTests.cs (4)
306
empty.
Sources
.Add(new ExtractionDocumentSourceReference(frame, DocumentAnnotationTestData.Polygon(), "NATIVE_ONLY"));
319
Assert.Same(frame, Assert.Single(empty.
Sources
).Page);
321
Assert.Equal(DocumentAnnotationTestData.Polygon(), empty.
Sources
[0].Polygon);
322
Assert.Equal("NATIVE_ONLY", empty.
Sources
[0].GetRawRepresentation());
DocumentTests.Composition.cs (2)
45
"empty-cell" => empty.
Sources
,
108
Assert.All(table.Cells, cell => Assert.Empty(cell!.
Sources
));
DocumentTests.StandardContent.cs (2)
401
firstCell.
Sources
.Add(reference);
414
Assert.Same(reference, Assert.Single(firstCell.
Sources
));