/**
* Tests toDerivative.
*/
public void toDerivativeBetweenTradeAndSettle() {
final ZonedDateTime referenceDate = DateUtils.getUTCDate(2011, 12, 13);
final DepositZero converted = DEPOSIT_DEFINITION.toDerivative(referenceDate);
final double startTime = TimeCalculator.getTimeBetween(referenceDate, SPOT_DATE);
final double endTime = TimeCalculator.getTimeBetween(referenceDate, END_DATE);
final DepositZero expected = new DepositZero(EUR, startTime, endTime, NOTIONAL, NOTIONAL, DEPOSIT_AF, RATE, DEPOSIT_DEFINITION.getInterestAmount());
assertEquals("DepositZeroDefinition: toDerivative", expected, converted);
}