Test_SNF_CS13_AddEventForPublicCalendar
open /portal
windowMaximize
echo -Add Task For Shared Calendar-
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
pause 5000
waitForElementPresent link=Agenda
click link=Agenda
echo -- Add event to public calendar
waitForElementPresent link=Event
click link=Event
waitForElementPresent //form[@id='UIQuickAddTask']//input[@id='eventName']
type //form[@id='UIQuickAddEvent']//input[@id='eventName'] Test_CS13_Event
type //form[@id='UIQuickAddEvent']//textarea[@id='description'] Test_CS13_Event_description
select calendar label=users-Default
click //div[@id='QuickAddEventContainer']//div[@class='ButtonRight']
waitForTextPresent Test_CS13_Event
verifyTextPresent Test_CS13_Event
click link=Logout
waitForElementNotPresent link=Logout
echo -- Login john to check the event public
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username john
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
pause 5000
waitForElementPresent link=Agenda
click link=Agenda
echo -- Search for and Delete Event
waitForElementPresent value
type value Test_CS13_Event
click //form[@id='UISearchForm']//div[@title='Search']
waitForElementPresent //div[@class='UIListView SpliterResizableListArea']//tr[@class='UIListViewRow']
click //div[@class='UIListView SpliterResizableListArea']//tr[@class='UIListViewRow']
waitForElementPresent //table[@id='RowContainerDay']//div[@class='IconHolder DeleteEventIcon']
click //table[@id='RowContainerDay']//div[@class='IconHolder DeleteEventIcon']
assertConfirmation Are you sure you want to delete?
clickAndWait link=Logout
close