コード例 #1
0
 @Test
 public void resetTable() {
   Long dinnerTableId = 1L;
   AcknowledgmentMessage message = this.resetTable(dinnerTableId);
   Assert.assertNotNull(message);
   Assert.assertTrue(AcknowledgmentMessage.Type.ERROR.equals(message.getType()));
 }
コード例 #2
0
 @Test
 public void updateTableCustomersNumber() {
   Long id = 1L;
   Integer customersNumber = 2;
   AcknowledgmentMessage message = this.updateTableCustomersNumber(id, customersNumber);
   Assert.assertNotNull(message);
   Assert.assertTrue(AcknowledgmentMessage.Type.ERROR.equals(message.getType()));
 }
コード例 #3
0
 @Test
 public void deleteOrderLine() {
   Long orderLineId = 1L;
   StringBuilder sb = new StringBuilder(context).append(OrdersController.DELETE_ORDER_LINE_ID);
   // Do not use delete method because the service returns nothing
   ResponseEntity<AcknowledgmentMessage> response =
       restTemplate.exchange(
           sb.toString(), HttpMethod.DELETE, null, AcknowledgmentMessage.class, orderLineId);
   Assert.assertNotNull(response.getBody());
   Assert.assertTrue(AcknowledgmentMessage.Type.ERROR.equals(response.getBody().getType()));
 }