@Test
public void tesSigninShouldBeSuccessful() {

    mockServer.expect()
            .post()
            .withPath("/api/v1/login")
            .andReturn(200, "{\"status\": \"success\",\"data\": {\"authToken\": \"token\",\"userId\": \"userid\"}}")
            .once();
    rest.signin("user", "password", loginCallback);
    verify(loginCallback, timeout(DEFAULT_TIMEOUT).only())
            .onLoginSuccess(tokenCaptor.capture());
    Token token = tokenCaptor.getValue();
    assertThat(token.userId(), is(equalTo("userid")));
    assertThat(token.authToken(), is(equalTo("token")));
    assertThat(token.expiresAt(), is(nullValue()));
}