@Test
public void getProfileByPublicUrl() {

	mockServer.expect(requestTo(LinkedInTemplate.BASE_URL + "url=https%3A%2F%2Fwww.linkedin.com%2Fin%2Fhabuma" + ProfileTemplate.PROFILE_FIELDS + "&oauth2_access_token=ACCESS_TOKEN"))
		.andExpect(method(GET))
		.andRespond(withSuccess(new ClassPathResource("profile.json", getClass()), MediaType.APPLICATION_JSON));
	LinkedInProfile profile = linkedIn.profileOperations().getProfileByPublicUrl("https://www.linkedin.com/in/habuma");
	assertEquals("z37f0n3A05", profile.getId());
	assertEquals("Just a guy", profile.getHeadline());
	assertEquals("Craig", profile.getFirstName());
	assertEquals("Walls", profile.getLastName());
	assertEquals("Computer Software", profile.getIndustry());
	assertEquals("https://www.linkedin.com/in/habuma", profile.getPublicProfileUrl());
	assertEquals("https://www.linkedin.com/standardProfileUrl", profile.getSiteStandardProfileRequest().getUrl());
	assertEquals("https://media.linkedin.com/pictureUrl", profile.getProfilePictureUrl());
}