use of org.opencds.cqf.cql.engine.runtime.Date in project quality-measure-and-cohort-service by Alvearie.
the class CQLToFHIRMeasureReportHelperTest method testIntervalDate_shouldReturnNull.
@Test
public void testIntervalDate_shouldReturnNull() {
Interval interval = new Interval(new Date("2020-01-02"), true, new Date("2020-06-04"), true);
assertNull(CQLToFHIRMeasureReportHelper.getFhirTypeValue(interval));
}
use of org.opencds.cqf.cql.engine.runtime.Date in project quality-measure-and-cohort-service by Alvearie.
the class CQLToFHIRMeasureReportHelperTest method testDate.
@Test
public void testDate() {
String dateString = "2020-01-02";
Date expected = new Date(dateString);
IBaseDatatype fhirTypeValue = CQLToFHIRMeasureReportHelper.getFhirTypeValue(expected);
assertTrue(fhirTypeValue instanceof DateType);
assertEquals(dateString, ((DateType) fhirTypeValue).getValueAsString());
}
Aggregations