SA_CleanUpTest
open /web/guest/home/
waitForElementPresent link=Control Panel
clickAtAndWait link=Control Panel
clickAtAndWait link=Web Content
store eval(selenium.isElementPresent('_15_rowIds')) webContentPresent
gotoIf !${webContentPresent} WebContentNotPresent
clickAt _15_allRowIds
clickAndWait //input[@value='Delete']
assertConfirmation Are you sure you want to delete the selected web content?
label WebContentNotPresent
open /web/guest/home/
waitForVisible link=Web Content Display Test Page
clickAtAndWait link=Web Content Display Test Page
store eval(selenium.isElementPresent('//section')) wcdPortletPresent
gotoIf !${wcdPortletPresent} WCDPortletNotPresent
click //img[@alt='Remove']
assertConfirmation Are you sure you want to remove this component?
label WCDPortletNotPresent
clickAt _145_addApplication
pause 5000
waitForVisible layout_configuration_content
typeKeys layout_configuration_content w
waitForVisible //div[@title='Web Content Display']/p/a
clickAt //div[@title='Web Content Display']/p/a
waitForVisible //section
assertVisible //section
waitForVisible link=Web Content List Test Page
clickAtAndWait link=Web Content List Test Page
store eval(selenium.isElementPresent('//section')) wclPortletPresent
gotoIf !${wclPortletPresent} WCLPortletNotPresent
click //img[@alt='Remove']
assertConfirmation Are you sure you want to remove this component?
label WCLPortletNotPresent
clickAt _145_addApplication
pause 5000
waitForVisible layout_configuration_content
typeKeys layout_configuration_content w
waitForVisible //div[@title='Web Content List']/p/a
clickAt //div[@title='Web Content List']/p/a
waitForVisible //section
assertVisible //section
waitForVisible link=Web Content Search Test Page
clickAtAndWait link=Web Content Search Test Page
store eval(selenium.isElementPresent('//section')) wcsPortletPresent
gotoIf !${wcsPortletPresent} WCSPortletNotPresent
click //img[@alt='Remove']
assertConfirmation Are you sure you want to remove this component?
label WCSPortletNotPresent
clickAt _145_addApplication
pause 5000
waitForVisible layout_configuration_content
typeKeys layout_configuration_content w
waitForVisible //div[@title='Web Content Search']/p/a
clickAt //div[@title='Web Content Search']/p/a
waitForVisible //section
assertElementPresent //section