@Test
  public void mapOrdersWithObs_shouldMapAllObservationsToLabOrderResults() {
    EncounterTransaction.Order order1 =
        createOrder("uuid1", "concept1", Order.Action.NEW.toString(), null);
    EncounterTransaction.Order order2 =
        createOrder("uuid2", "concept2", Order.Action.REVISE.toString(), null);
    List<EncounterTransaction.Order> testOrders = Arrays.asList(order1, order2);
    EncounterTransaction.Observation order1_Obs1 = createObservation("obsuuid1", order1.getUuid());
    EncounterTransaction.Observation order1_Obs2 = createObservation("obsuuid2", order1.getUuid());
    EncounterTransaction.Observation order2_Obs1 = createObservation("obsuuid3", order2.getUuid());
    List<EncounterTransaction.Observation> observations =
        Arrays.asList(order1_Obs1, order1_Obs2, order2_Obs1);
    Map<String, Encounter> orderToEncounterMapping = new HashMap<>();
    orderToEncounterMapping.put(order1.getUuid(), encounter);
    orderToEncounterMapping.put(order2.getUuid(), encounter);
    Map<String, Encounter> observationToEncounterMapping = new HashMap<>();
    observationToEncounterMapping.put(order1_Obs1.getUuid(), encounter);
    observationToEncounterMapping.put(order1_Obs2.getUuid(), encounter);
    observationToEncounterMapping.put(order2_Obs1.getUuid(), encounter);

    List<LabOrderResult> results =
        labOrderResultsServiceImpl.mapOrdersWithObs(
            testOrders,
            observations,
            orderToEncounterMapping,
            observationToEncounterMapping,
            new HashMap());

    assertEquals(3, results.size());
  }
  @Test
  public void mapOrdersWithObs_shouldMapLabTestWithoutResultToLabOrderResult() {
    EncounterTransaction.Order order1 =
        createOrder("uuid1", "concept1", Order.Action.NEW.toString(), null);
    List<EncounterTransaction.Order> testOrders = Arrays.asList(order1);
    Map<String, Encounter> orderToEncounterMapping = new HashMap<>();
    orderToEncounterMapping.put(order1.getUuid(), encounter);

    List<LabOrderResult> results =
        labOrderResultsServiceImpl.mapOrdersWithObs(
            testOrders,
            new ArrayList<EncounterTransaction.Observation>(),
            orderToEncounterMapping,
            new HashMap(),
            new HashMap());

    assertEquals(1, results.size());
  }