### Question:
UserTemplate extends AbstractTwitterOperations implements UserOperations { public TwitterProfile getUserProfile() { requireUserAuthorization(); return restTemplate.getForObject(buildUri("account/verify_credentials.json"), TwitterProfile.class); } UserTemplate(RestTemplate restTemplate, boolean isAuthorizedForUser, boolean isAuthorizedForApp); long getProfileId(); String getScreenName(); TwitterProfile getUserProfile(); TwitterProfile getUserProfile(String screenName); TwitterProfile getUserProfile(long userId); List<TwitterProfile> getUsers(long... userIds); List<TwitterProfile> getUsers(String... screenNames); List<TwitterProfile> searchForUsers(String query); List<TwitterProfile> searchForUsers(String query, int page, int pageSize); List<SuggestionCategory> getSuggestionCategories(); List<TwitterProfile> getSuggestions(String slug); Map<ResourceFamily, List<RateLimitStatus>> getRateLimitStatus(ResourceFamily... resources); AccountSettings getAccountSettings(); AccountSettings updateAccountSettings(AccountSettingsData accountSettingsData);  }### Answer:
@Test public void getUserProfile() throws Exception { mockServer.expect(requestTo("https: .andExpect(method(GET)) .andRespond(withSuccess(jsonResource("twitter-profile"), APPLICATION_JSON)); TwitterProfile profile = twitter.userOperations().getUserProfile(); assertEquals(161064614, profile.getId()); assertEquals("161064614", profile.getIdStr()); assertEquals("artnames", profile.getScreenName()); assertEquals("Art Names", profile.getName()); assertEquals("I'm just a normal kinda guy", profile.getDescription()); assertEquals("Denton, TX", profile.getLocation()); assertEquals("https: assertEquals("https: assertTrue(profile.isNotificationsEnabled()); assertFalse(profile.isVerified()); assertTrue(profile.isGeoEnabled()); assertTrue(profile.isContributorsEnabled()); assertTrue(profile.isTranslator()); assertTrue(profile.isFollowing()); assertTrue(profile.isFollowRequestSent()); assertTrue(profile.isProtected()); assertEquals("en", profile.getLanguage()); assertEquals(125, profile.getStatusesCount()); assertEquals(1001, profile.getListedCount()); assertEquals(14, profile.getFollowersCount()); assertEquals(194, profile.getFriendsCount()); assertEquals(4, profile.getFavoritesCount()); assertEquals("Mountain Time (US & Canada)", profile.getTimeZone()); assertEquals(-25200, profile.getUtcOffset()); assertTrue(profile.useBackgroundImage()); assertEquals("C0DEED", profile.getSidebarBorderColor()); assertEquals("DDEEF6", profile.getSidebarFillColor()); assertEquals("C0DEED", profile.getBackgroundColor()); assertEquals("https: assertFalse(profile.isBackgroundImageTiled()); assertEquals("333333", profile.getTextColor()); assertEquals("0084B4", profile.getLinkColor()); }