@Test public void testGetCurrentUserProfile(){ Long currentUserId = 4022983L; mockServer.expect(requestTo("https: .andExpect(method(GET)) .andRespond(withSuccess(jsonResource("testdata/yammer-user"), APPLICATION_JSON)); YammerProfile yProfile = yammerTemplate.userOperations().getUserProfile(); assertThat(yProfile.getId(), equalTo(currentUserId)); assertYammerProfile(yProfile); }
public YammerProfile getUserProfile(){ return restTemplate.getForObject(buildUri("users/current.json"), YammerProfile.class); }
UserTemplate extends AbstractYammerOperations implements UserOperations { public YammerProfile getUserProfile(){ return restTemplate.getForObject(buildUri("users/current.json"), YammerProfile.class); } }
UserTemplate extends AbstractYammerOperations implements UserOperations { public YammerProfile getUserProfile(){ return restTemplate.getForObject(buildUri("users/current.json"), YammerProfile.class); } UserTemplate(RestTemplate restTemplate); }
UserTemplate extends AbstractYammerOperations implements UserOperations { public YammerProfile getUserProfile(){ return restTemplate.getForObject(buildUri("users/current.json"), YammerProfile.class); } UserTemplate(RestTemplate restTemplate); List<YammerProfile> getUsers(int page); List<YammerProfile> getUsers(int page, String sortBy, boolean reverse, Character letter); YammerProfile getUser(long id); YammerProfile getUser(String userId); void updateProfile(long userId, UserInfo userInfo); YammerProfile getUserProfile(); YammerProfile getUserByEmail(String email); }
UserTemplate extends AbstractYammerOperations implements UserOperations { public YammerProfile getUserProfile(){ return restTemplate.getForObject(buildUri("users/current.json"), YammerProfile.class); } UserTemplate(RestTemplate restTemplate); List<YammerProfile> getUsers(int page); List<YammerProfile> getUsers(int page, String sortBy, boolean reverse, Character letter); YammerProfile getUser(long id); YammerProfile getUser(String userId); void updateProfile(long userId, UserInfo userInfo); YammerProfile getUserProfile(); YammerProfile getUserByEmail(String email);  }