Test_PRL_01_017_CreateNewAccountWhenFirstNameStartsWithNumber
open /portal/public/classic/
echo -- Create new account when First Name starts with number--
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
echo -- Go to New Staff--
clickAndWait link=New Staff
waitForElementPresent username
type username Test_PRL_01_017
type password Test_PRL_01_017
type Confirmpassword Test_PRL_01_017
type firstName 01_017
type lastName Test_PRL_01_017
type email Test_PRL_01_017@gmail.com
echo -- Choose user Profile --
waitForElementPresent //div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div
click //div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div
waitForElementPresent user.language
select user.language label=German
waitForElementPresent link=Save
click link=Save
waitForElementPresent //div[3]/div/div/div/div/div[2]
verifyText //div[3]/div/div/div/div/div[2] You have registered a new account.
waitForElementPresent //div[3]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div
click //div[3]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div
waitForElementPresent link=Sign out
clickAndWait link=Sign out
echo -- Login with new user--
open /portal/public/classic/
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username Test_PRL_01_017
type password Test_PRL_01_017
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
waitForElementPresent link=01_017 Test_PRL_01_017
verifyText link=01_017 Test_PRL_01_017 01_017 Test_PRL_01_017
clickAndWait link=Abmelden
echo -- Login with administrator to delete new user--
open /portal/public/classic/
waitForElementPresent link=Sign in
click link=Sign in
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
echo -- Go to user and group management--
waitForElementPresent link=Users and groups management
click link=Users and groups management
echo -- Search new user in list--
waitForElementPresent searchTerm
type searchTerm Test_PRL_01_017
waitForElementPresent //form[@id='UISearchForm']/div[2]/a
click //form[@id='UISearchForm']/div[2]/a
echo -- Delete new user--
waitForElementPresent //img[@alt='DeleteUser']
click //img[@alt='DeleteUser']
assertConfirmation Are you sure you want to delete Test_PRL_01_017 user?
waitForElementPresent link=Sign out
clickAndWait link=Sign out