From 28ccb2a65c0573268e097f1c3d75b95dbee5ef8e Mon Sep 17 00:00:00 2001 From: Sylvain Jermini Date: Tue, 11 Jun 2019 15:02:20 +0200 Subject: [PATCH] check invoice/receipt #588 --- .../api/v2/user/ReservationFlowIntegrationTest.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/test/java/alfio/controller/api/v2/user/ReservationFlowIntegrationTest.java b/src/test/java/alfio/controller/api/v2/user/ReservationFlowIntegrationTest.java index 3564d175d4..2d9563e093 100644 --- a/src/test/java/alfio/controller/api/v2/user/ReservationFlowIntegrationTest.java +++ b/src/test/java/alfio/controller/api/v2/user/ReservationFlowIntegrationTest.java @@ -622,6 +622,11 @@ public void reservationFlowTest() throws Exception { assertEquals(HttpStatus.BAD_REQUEST, releaseTicketFailure.getStatusCode()); assertEquals(HttpStatus.OK, ticketApiV2Controller.getTicketInfo(event.getShortName(), ticket.getUuid()).getStatusCode()); + + //no invoice, but receipt + assertEquals(HttpStatus.NOT_FOUND, reservationApiV2Controller.getInvoice(event.getShortName(), reservationId, new MockHttpServletResponse(), null).getStatusCode()); + assertEquals(HttpStatus.OK, reservationApiV2Controller.getReceipt(event.getShortName(), reservationId, new MockHttpServletResponse(), null).getStatusCode()); + } }