kryo.register(LinkedIn2Company.class);
}
@Override
protected void verifyProfile(final UserProfile userProfile) {
final LinkedIn2Profile profile = (LinkedIn2Profile) userProfile;
logger.debug("profile : {}", profile);
assertEquals("JJjS_5BOzW", profile.getId());
assertEquals(LinkedIn2Profile.class.getSimpleName() + UserProfile.SEPARATOR + "JJjS_5BOzW",
profile.getTypedId());
assertTrue(ProfileHelper.isTypedIdOf(profile.getTypedId(), LinkedIn2Profile.class));
assertTrue(StringUtils.isNotBlank(profile.getAccessToken()));
assertCommonProfile(userProfile,
"testscribeup@gmail.com",
"test",
"scribeUp",
"test scribeUp",
null,
Gender.UNSPECIFIED,
null,
"http://m.c.lnkd.licdn.com/mpr/mprx/0_XGm9Ldp1WfMsB74Zk32WLwptW7DZvoWZQisWLwSfnuJeEmY4eXYVwIJ3bFSb9DeNL3uHo21cF5lC",
"http://www.linkedin.com/pub/test-scribeup/48/aa/16b", "Paris Area, France");
final LinkedIn2Location location = profile.getCompleteLocation();
assertEquals("Paris Area, France", location.getName());
assertEquals("fr", location.getCode());
assertNull(profile.getMaidenName());
assertEquals("ScribeUP développeur chez OpenSource", profile.getHeadline());
assertEquals("Information Technology and Services", profile.getIndustry());
assertEquals(1, profile.getNumConnections().intValue());
assertEquals("This is a summary...", profile.getSummary());
assertNull(profile.getSpecialties());
final List<LinkedIn2Position> positions = profile.getPositions();
assertEquals(2, positions.size());
final LinkedIn2Position position = positions.get(0);
assertEquals("417494299", position.getId());
assertEquals("Developer", position.getTitle());
assertEquals("Desc", position.getSummary());
final LinkedIn2Date startDate = position.getStartDate();
assertEquals(2012, startDate.getYear().intValue());
assertEquals(3, startDate.getMonth().intValue());
assertTrue(position.getIsCurrent().booleanValue());
assertNull(position.getEndDate());
final LinkedIn2Company company = position.getCompany();
assertEquals("PAC4J", company.getName());
assertNull(company.getIndustry());
assertEquals("http://www.linkedin.com/profile/view?id=167439971&authType=name&authToken=_IWF&trk=api*a167383*s175634*",
profile.getSiteStandardProfileRequest());
assertEquals("167439971", profile.getOAuth10Id());
assertEquals(14, profile.getAttributes().size());
}