### Question:
DoseQuantityChoiceNode extends ChoiceNode { @Override public Object getValue(Object obj) { final double value = (Double) super.getValue(obj); return DoseUnit.convert(value, (DoseUnit) BeanUtils.getValue(obj, d_descriptor), d_doseUnit); } DoseQuantityChoiceNode(Class<?> beanClass, String propertyName, DoseUnit doseUnit); @Override Object getValue(Object obj); DoseUnit getDoseUnit(); @Override boolean equivalent(DecisionTreeNode o);  }### Answer:
@Test public void testGetValue() { FixedDose dose = new FixedDose(13, DoseUnit.createMilliGramsPerDay()); ChoiceNode choiceNode = new DoseQuantityChoiceNode(FixedDose.class, FixedDose.PROPERTY_QUANTITY, DoseUnit.createMilliGramsPerDay()); assertEquals(dose.getQuantity(), choiceNode.getValue(dose)); }
@Test public void testGetValueConversion() { FixedDose dose = new FixedDose(2400, DoseUnit.createMilliGramsPerDay()); ChoiceNode choiceNode = new DoseQuantityChoiceNode(FixedDose.class, FixedDose.PROPERTY_QUANTITY, ExampleData.KILOGRAMS_PER_HOUR); assertEquals(0.0001, (Double)choiceNode.getValue(dose), 0.000001); }