use of com.ibm.cohort.engine.measure.FHIRClientContext.Builder in project quality-measure-and-cohort-service by Alvearie.
the class R4DataProviderFactoryTest method createDataProviderMap_noCacheContext.
@Test
public void createDataProviderMap_noCacheContext() {
IGenericClient client = new Builder().withDefaultClient(getFhirServerConfig()).build().getDataClient();
CqlTerminologyProvider terminologyProvider = new R4RestFhirTerminologyProvider(client);
Map<String, CqlDataProvider> map = R4DataProviderFactory.createDataProviderMap(client, terminologyProvider, null);
verifyDataProviderMap(map);
}
use of com.ibm.cohort.engine.measure.FHIRClientContext.Builder in project quality-measure-and-cohort-service by Alvearie.
the class R4DataProviderFactoryTest method createDataProviderMap_withCacheContext.
@Test
public void createDataProviderMap_withCacheContext() throws Exception {
IGenericClient client = new Builder().withDefaultClient(getFhirServerConfig()).build().getDataClient();
CqlTerminologyProvider terminologyProvider = new R4RestFhirTerminologyProvider(client);
try (RetrieveCacheContext cacheContext = new DefaultRetrieveCacheContext(new CaffeineConfiguration<>())) {
Map<String, CqlDataProvider> map = R4DataProviderFactory.createDataProviderMap(client, terminologyProvider, cacheContext);
verifyDataProviderMap(map);
}
}
Aggregations