use of org.hl7.fhir.dstu3.model.CodeSystem in project beneficiary-fhir-data by CMSgov.
the class InpatientClaimTransformerV2Test method shouldHaveExpectedCodingValues.
@Test
public void shouldHaveExpectedCodingValues() {
CodeableConcept compare = new CodeableConcept().setCoding(Arrays.asList(new Coding("https://bluebutton.cms.gov/resources/variables/nch_clm_type_cd", "60", "Inpatient claim"), new Coding("https://bluebutton.cms.gov/resources/codesystem/eob-type", "INPATIENT", null), new Coding("http://terminology.hl7.org/CodeSystem/claim-type", "institutional", "Institutional")));
assertTrue(compare.equalsDeep(eob.getType()));
}
use of org.hl7.fhir.dstu3.model.CodeSystem in project beneficiary-fhir-data by CMSgov.
the class HHAClaimTransformerV2Test method shouldHaveLineItemRevenue.
@Test
public void shouldHaveLineItemRevenue() {
CodeableConcept revenue = eob.getItemFirstRep().getRevenue();
Coding code1 = revenue.getCoding().stream().filter(coding -> coding.getSystem().equals("https://bluebutton.cms.gov/resources/variables/rev_cntr")).findFirst().orElse(null);
Coding code2 = revenue.getCoding().stream().filter(coding -> coding.getSystem().equals("https://www.nubc.org/CodeSystem/RevenueCodes")).findFirst().orElse(null);
Coding code3 = revenue.getCoding().stream().filter(coding -> coding.getSystem().equals("https://bluebutton.cms.gov/resources/variables/rev_cntr_ddctbl_coinsrnc_cd")).findFirst().orElse(null);
assertNotNull(code1, "Missing expected rev_cntr coding");
assertEquals("0023", code1.getCode());
assertEquals("Home Health services paid under PPS submitted as TOB 32X and 33X, effective 10/00. This code may appear multiple times on a claim to identify different HIPPS/Home Health Resource Groups (HRG).", code1.getDisplay());
assertNotNull(code2, "Missing expected RevenueCodes coding");
assertEquals("4", code2.getCode());
assertNull(code2.getDisplay());
assertNotNull(code3, "Missing expected rev_cntr_ddctbl_coinsrnc_cd coding");
assertEquals("4", code3.getCode());
assertEquals("No charge or units associated with this revenue center code. (For multiple HCPCS per single revenue center code) For revenue center code 0001, the following MSP override values may be present:", code3.getDisplay());
}
use of org.hl7.fhir.dstu3.model.CodeSystem in project beneficiary-fhir-data by CMSgov.
the class HHAClaimTransformerV2Test method shouldHaveClaimReceivedDateSupInfo.
@Test
public void shouldHaveClaimReceivedDateSupInfo() {
SupportingInformationComponent sic = TransformerTestUtilsV2.findSupportingInfoByCode("clmrecvddate", eob.getSupportingInfo());
SupportingInformationComponent compare = TransformerTestUtilsV2.createSupportingInfo(// We don't care what the sequence number is here
sic.getSequence(), // Category
Arrays.asList(new Coding("http://hl7.org/fhir/us/carin-bb/CodeSystem/C4BBSupportingInfoType", "clmrecvddate", "Claim Received Date"), new Coding("https://bluebutton.cms.gov/resources/codesystem/information", "https://bluebutton.cms.gov/resources/variables/nch_wkly_proc_dt", "NCH Weekly Claim Processing Date"))).setTiming(new DateType("2015-11-06"));
assertTrue(compare.equalsDeep(sic));
}
use of org.hl7.fhir.dstu3.model.CodeSystem in project beneficiary-fhir-data by CMSgov.
the class HHAClaimTransformerV2Test method shouldHaveLineItemAdjudicationRevCntrNcrvdChrgAmt.
@Test
public void shouldHaveLineItemAdjudicationRevCntrNcrvdChrgAmt() {
AdjudicationComponent adjudication = TransformerTestUtilsV2.findAdjudicationByCategory("https://bluebutton.cms.gov/resources/variables/rev_cntr_ncvrd_chrg_amt", eob.getItemFirstRep().getAdjudication());
// Need to maintain trailing 0s in USD amount
BigDecimal amt = new BigDecimal(24.00);
amt = amt.setScale(2, RoundingMode.HALF_DOWN);
AdjudicationComponent compare = new AdjudicationComponent().setCategory(new CodeableConcept().setCoding(Arrays.asList(new Coding("http://hl7.org/fhir/us/carin-bb/CodeSystem/C4BBAdjudication", "noncovered", "Noncovered"), new Coding("https://bluebutton.cms.gov/resources/codesystem/adjudication", "https://bluebutton.cms.gov/resources/variables/rev_cntr_ncvrd_chrg_amt", "Revenue Center Non-Covered Charge Amount")))).setAmount(new Money().setValue(amt).setCurrency(TransformerConstants.CODED_MONEY_USD));
assertTrue(compare.equalsDeep(adjudication));
}
use of org.hl7.fhir.dstu3.model.CodeSystem in project beneficiary-fhir-data by CMSgov.
the class HHAClaimTransformerV2Test method shouldHaveClmTotChrgAmtTotal.
@Test
public void shouldHaveClmTotChrgAmtTotal() {
// Only one so just pull it directly and compare
TotalComponent total = eob.getTotalFirstRep();
TotalComponent compare = new TotalComponent().setCategory(new CodeableConcept().setCoding(Arrays.asList(new Coding("http://terminology.hl7.org/CodeSystem/adjudication", "submitted", "Submitted Amount"), new Coding("https://bluebutton.cms.gov/resources/codesystem/adjudication", "https://bluebutton.cms.gov/resources/variables/clm_tot_chrg_amt", "Claim Total Charge Amount")))).setAmount(new Money().setValue(199.99).setCurrency(TransformerConstants.CODED_MONEY_USD));
assertTrue(compare.equalsDeep(total));
}
Aggregations