@Test
  public void testUpdate() throws Exception {
    UserMeal updated = getUpdated();

    mockMvc
        .perform(
            put(REST_URL + MEAL1_ID)
                .contentType(MediaType.APPLICATION_JSON)
                .content(JsonUtil.writeValue(updated))
                .with(userHttpBasic(USER)))
        .andExpect(status().isOk());

    assertEquals(updated, service.get(MEAL1_ID, START_SEQ));
  }
 public UserMeal get(int id) {
   int userId = LoggedUser.id();
   LOG.info("get meal {} for User {}", id, userId);
   return service.get(id, userId);
 }