public final void testThreshold_ChartOfAccount_Invalid() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE_INVALID); assertTrue(thresholdRule.processSaveDocument(doc)); assertTrue(thresholdRule.processRouteDocument(doc)); assertTrue(GlobalVariables.getMessageMap().hasErrors()); assertEquals(1, GlobalVariables.getMessageMap().getErrorCount()); assertTrue( GlobalVariables.getMessageMap() .getErrorMessages() .containsKey("document.newMaintainableObject.chartOfAccountsCode")); }
public final void testThreshold_ChartOfAccountAndAccountTypeAndSubAccountType() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE_AND_ACCOUNTTYPE_AND_SUBACCOUNTTYPE); assertTrue(thresholdRule.processSaveDocument(doc)); assertFalse(thresholdRule.processRouteDocument(doc)); assertTrue(GlobalVariables.getMessageMap().hasErrors()); assertEquals(2, GlobalVariables.getMessageMap().getErrorCount()); assertTrue( GlobalVariables.getMessageMap() .getErrorMessages() .containsKey("document.newMaintainableObject.accountTypeCode")); assertTrue( GlobalVariables.getMessageMap() .getErrorMessages() .containsKey("document.newMaintainableObject.subFundGroupCode")); }
public final void testThreshold_InvalidDescription() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE); doc.getDocumentHeader().setDocumentDescription(null); assertFalse(thresholdRule.processSaveDocument(doc)); assertTrue(GlobalVariables.getMessageMap().hasErrors()); assertTrue( GlobalVariables.getMessageMap() .getErrorMessages() .containsKey("document.documentHeader.documentDescription")); }
public final void testThreshold_ChartOfAccountAndSubAccountType() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE_AND_SUBACCOUNTTYPE); assertTrue(thresholdRule.processSaveDocument(doc)); }
public final void testThreshold_ChartOfAccount() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE); assertTrue(thresholdRule.processSaveDocument(doc)); }
public final void testThreshold_ChartOfAccountAndVendorNumber() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE_AND_VENDORNUMBER); assertTrue(thresholdRule.processSaveDocument(doc)); }
public final void testThreshold_ChartOfAccountAndCommodityCode() { MaintenanceDocumentBase doc = getMaintenanceDocument(ThresholdFixture.CHARTCODE_AND_COMMODITYCODE); assertTrue(thresholdRule.processSaveDocument(doc)); }