IDEMPIERE-4747 Pass PO object from MWFProcess to MWFActivity (#646)

Fix unit test error.
This commit is contained in:
hengsin 2021-04-08 21:20:49 +08:00 committed by GitHub
parent cb53fbcce0
commit b22ceeabdf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 0 deletions

View File

@ -369,6 +369,11 @@ public class DocumentEngine implements DocAction
continue; continue;
@SuppressWarnings("unused") @SuppressWarnings("unused")
String ignoreError = DocumentEngine.postImmediate(docafter.getCtx(), docafter.getAD_Client_ID(), docafter.get_Table_ID(), docafter.get_ID(), true, docafter.get_TrxName()); String ignoreError = DocumentEngine.postImmediate(docafter.getCtx(), docafter.getAD_Client_ID(), docafter.get_Table_ID(), docafter.get_ID(), true, docafter.get_TrxName());
if (!Util.isEmpty(ignoreError, true)) {
log.warning("Error posting " + docafter + ". Error="+ignoreError);
} else {
docafter.load(docafter.get_TrxName());
}
} }
} }
} }

View File

@ -282,6 +282,7 @@ public class MatchPOTest extends AbstractTestCase {
assertFalse(info.isError(), info.getSummary()); assertFalse(info.isError(), info.getSummary());
invoice.load(getTrxName()); invoice.load(getTrxName());
assertEquals(DocAction.STATUS_Completed, invoice.getDocStatus()); assertEquals(DocAction.STATUS_Completed, invoice.getDocStatus());
invoice.getDocsPostProcess().clear();
info = MWorkflow.runDocumentActionWorkflow(invoice, DocAction.ACTION_Reverse_Accrual); info = MWorkflow.runDocumentActionWorkflow(invoice, DocAction.ACTION_Reverse_Accrual);
assertFalse(info.isError(), info.getSummary()); assertFalse(info.isError(), info.getSummary());