profile: Harden test TestInvoice#testKB_REUSE_DRAFT_INVOICING_ID
@@ -999,7 +999,12 @@ public class TestInvoice extends TestJaxrsBase {
final LocalDate futureDate = clock.getUTCToday();
final Map<String, String> properties = new HashMap<>();
properties.put("KB_REUSE_DRAFT_INVOICING_ID", invoiceId.toString());
+
+ callbackServlet.pushExpectedEvents(ExtBusEventType.INVOICE_CREATION,
+ ExtBusEventType.INVOICE_ADJUSTMENT);
final Invoice invoice = invoiceApi.createFutureInvoice(accountJson.getAccountId(), futureDate, properties, requestOptions);
+ callbackServlet.assertListenerStatus();
+
assertEquals(invoice.getAmount(), new BigDecimal("19.95"));
// CREDIT_ADJ -10, CBA_ADJ +10 -> CBA generation from initial credit call on the Draft invoice
// RECURRING 29.95, CBA_ADJ -10 -> RECURRING and CBA use from invoice run (on the same invoice)
