@Test
public void returnsTokenOfAuthenticatedUser() throws Exception {

  when(fibonacciService.term(term)).thenReturn(expected);
  mockMvc.perform(
      get("/fibonacci/term")
          .param("n", String.valueOf(term)))
      .andExpect(status().isOk())
      .andExpect(content().string(String.valueOf(expected)));
}