/** * Validates that validateEndowmentTransactionTypeCode returns false when the etran code type is * not income or expense. */ public void testEtranCodeIncomeOrExpense_False() { EndowmentTransactionLine endowmentTargetTransactionLine = EndowmentTransactionLineFixture.ENDOWMENT_TRANSACTIONAL_LINE_POSITIVE_AMT .createEndowmentTransactionLine(false); EndowmentTransactionCode endowmentTransactionCode = EndowmentTransactionCodeFixture.ASSET_TRANSACTION_CODE.createEndowmentTransactionCode(); endowmentTargetTransactionLine.setEtranCode(endowmentTransactionCode.getCode()); endowmentTargetTransactionLine.setEtranCodeObj(endowmentTransactionCode); assertFalse( rule.validateEndowmentTransactionTypeCode( document, endowmentTargetTransactionLine, rule.getErrorPrefix(endowmentTargetTransactionLine, -1))); }