public void GivenVariableNumberAndDoubleWhenSubtractFromSourceShouldDoThat() { var uom = _ftUnitOfMeasure.ToModelUom(); var value = new NumericValue(uom, 24.68); var number = new NumericRepresentationValue(RepresentationInstanceList.vrABShiftTrack.ToModelRepresentation(), value); number.SubtractFromSource(10.11); Assert.AreEqual(14.57, number.Value.Value); }
public void GivenVariableNumberWhenSubtractVariableNumberFromSourceShouldDoThat() { var uom = _ftUnitOfMeasure.ToModelUom(); var firstValue = new NumericValue(uom, 24.68); var secondValue = new NumericValue(uom, 10.11); var firstNumber = new NumericRepresentationValue(RepresentationInstanceList.vrABShiftTrack.ToModelRepresentation(), firstValue); var secondNumber = new NumericRepresentationValue(RepresentationInstanceList.vrABShiftTrack.ToModelRepresentation(), secondValue); firstNumber.SubtractFromSource(secondNumber); Assert.AreEqual(14.57, firstNumber.Value.Value); }