use of org.molgenis.data.elasticsearch.generator.model.Document in project molgenis by molgenis.
the class DocumentContentBuilderTest method createDocumentDecimal.
@Test(dataProvider = "createDocumentDecimal")
public void createDocumentDecimal(Double value, String expectedContent) {
String attrIdentifier = "attr";
Entity entity = createEntity(attrIdentifier, AttributeType.DECIMAL);
when(entity.getDouble(attrIdentifier)).thenReturn(value);
Document document = documentContentBuilder.createDocument(entity);
assertDocumentEquals(document, expectedContent);
}
Aggregations