Amount implements InternalModelTransformer, Serializable { @Override public InternalModelObject transformToInternalModel() { com.worldpay.internal.model.Amount intAmount = new com.worldpay.internal.model.Amount(); intAmount.setValue(value); intAmount.setCurrencyCode(currencyCode); intAmount.setExponent(exponent); if (debitCreditIndicator != null) { intAmount.setDebitCreditIndicator(debitCreditIndicator.getCode()); } return intAmount; } Amount(String value, String currencyCode, String exponent);  Amount(String value, String currencyCode, String exponent, DebitCreditIndicator debitCreditIndicator); @Override InternalModelObject transformToInternalModel(); String getValue(); void setValue(String value); String getCurrencyCode(); void setCurrencyCode(String currencyCode); String getExponent(); void setExponent(String exponent); DebitCreditIndicator getDebitCreditIndicator(); void setDebitCreditIndicator(DebitCreditIndicator debitCreditIndicator); @Override String toString();  }
@Test public void shouldReturnAnAmount() { final Amount amount = new Amount(null, null, null); final InternalModelObject result = amount.transformToInternalModel(); assertTrue(result instanceof com.worldpay.internal.model.Amount); }