Test_SNF_PRL_67_ChangePassword
open /portal/public/classic/
echo -- Change Password --
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']
clickAndWait link=New Staff
waitForElementPresent username
type username Test_SNF_PRL_67
type password Test_SNF_PRL_67
type Confirmpassword Test_SNF_PRL_67
type firstName Test_SNF_PRL_67
type lastName Test_SNF_PRL_67
type email Test_SNF_PRL_67@gmail.com
echo -- Choose user Profile tab --
waitForElementPresent //div[text()='User Profile']
click //div[text()='User Profile']
waitForElementPresent user.language
select user.language label=English
waitForElementPresent link=Save
click link=Save
waitForTextPresent You have registered a new account.
verifyTextPresent You have registered a new account.
waitForElementPresent //div[@id="UIAccountPortlet"]//a[text()="OK"]
click //div[@id="UIAccountPortlet"]//a[text()="OK"]
clickAndWait link=Sign out
echo -- Login by new user --
open /portal/public/classic/
click link=Sign in
waitForElementPresent username
type username Test_SNF_PRL_67
type password Test_SNF_PRL_67
clickAndWait //div[@id='UIPortalLoginFormAction']
waitForTextPresent Test_SNF_PRL_67 Test_SNF_PRL_67
verifyTextPresent Test_SNF_PRL_67 Test_SNF_PRL_67
waitForElementPresent link=Test_SNF_PRL_67 Test_SNF_PRL_67
click link=Test_SNF_PRL_67 Test_SNF_PRL_67
echo -- Change Password--
waitForElementPresent link=Change Password
click link=Change Password
waitForElementPresent currentpass
type currentpass Test_SNF_PRL_67
type newpass Test_SNF_PRL_67_edit
type confirmnewpass Test_SNF_PRL_67_edit
waitForElementPresent //div[@class='UIForm UIAccountChangePass']//a[text()="Save"]
click //div[@class='UIForm UIAccountChangePass']//a[text()="Save"]
waitForTextPresent The password has been changed.
verifyTextPresent The password has been changed.
waitForElementPresent //div[6]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div
click //div[6]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div
click link=Close
clickAndWait link=Sign out
echo -- Login by new user after change password --
open /portal/public/classic/
click link=Sign in
waitForElementPresent username
type username Test_SNF_PRL_67
type password Test_SNF_PRL_67_edit
clickAndWait //div[@id='UIPortalLoginFormAction']
waitForTextPresent Test_SNF_PRL_67 Test_SNF_PRL_67
verifyTextPresent Test_SNF_PRL_67 Test_SNF_PRL_67
clickAndWait link=Sign out
echo -- Login by admin--
open /portal/public/classic/
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']
clickAndWait link=Users and groups management
echo -- Search new user --
waitForElementPresent searchTerm
type searchTerm Test_SNF_PRL_67
waitForElementPresent //a[@title='Quick Search']
click //a[@title='Quick Search']
echo -- Delete user --
waitForElementPresent //img[@alt='DeleteUser']
click //img[@alt='DeleteUser']
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete Test_SNF_PRL_67 user?
waitForTextNotPresent Test_SNF_PRL_67
verifyTextNotPresent Test_SNF_PRL_67
waitForElementPresent link=Sign out
clickAndWait link=Sign out