use of com.wikia.webdriver.pageobjectsfactory.componentobject.editprofile.AvatarComponentObject in project selenium-tests by Wikia.
the class UserAvatar method staffUserCanUploadAvatar.
@Test(groups = "UserAvatar_staffUserCanUploadAvatar")
@Execute(asUser = User.STAFF)
public void staffUserCanUploadAvatar() {
UserProfilePageObject profile = new UserProfilePageObject(driver).openProfilePage(credentials.userNameStaff, wikiURL);
AvatarComponentObject avatar = profile.clickEditAvatar();
profile.verifyAvatar();
String avatarUrl = profile.getAvatarImageSrc();
avatar.uploadAvatar(PageContent.FILE);
avatar.saveProfile();
profile.verifyAvatarChanged(avatarUrl);
String changedAvatarUrl = profile.getAvatarImageSrc();
profile.verifyAvatarVisible();
Assertion.assertNotEquals(changedAvatarUrl, avatarUrl);
profile.verifyURLStatus(200, changedAvatarUrl);
}
Aggregations