Test_SNF_ECMS_02_CreateCLVPageByFolder_ecmdemo
open /portal/public/acme/
windowMaximize
echo -- Log in
click link=Login
waitForElementPresent username
type username root
type password gtn
clickAndWait link=Sign in
echo -- Create CLV page
waitForElementPresent link=Add Page
click link=Add Page
waitForElementPresent //div[@id='UIPageNodeSelector']/div/div/div[2]/div/div/div/div[1]/a
click //div[@id='UIPageNodeSelector']/div/div/div[2]/div/div/div/div[1]/a
pause 2000
waitForElementPresent pageName
type pageName ASnfEcms02
waitForElementPresent //div[@id='UIPageCreationWizard']/div/div[3]/div/div/div/div[2]/div/table/tbody/tr/td/div[2]/div/div/div
click //div[@id='UIPageCreationWizard']/div/div[3]/div/div/div/div[2]/div/table/tbody/tr/td/div[2]/div/div/div
pause 2000
waitForElementPresent //div[@id='UIPageCreationWizard']/div/div[3]/div/div/div/div[2]/div/table/tbody/tr/td/div[2]/div/div/div
click //div[@id='UIPageCreationWizard']/div/div[3]/div/div/div/div[2]/div/table/tbody/tr/td/div[2]/div/div/div
waitForElementPresent link=Contents
click link=Contents
echo Drag a content list
waitForElementPresent //div[text()='Content List']
dragAndDropToObject //div[text()='Content List'] //div[@id='UIPagePreview']/div[@class='UIPage']//div[@class='UIComponentBlock']
waitForElementPresent //a[@title='Edit Portlet']
mouseOver //a[@title='Edit Portlet']
click //a[@title='Edit Portlet']
echo -- check By Folder
waitForElementPresent //input[@name='UICLVConfigDisplayModeFormRadioBoxInput']
check //input[@name='UICLVConfigDisplayModeFormRadioBoxInput']
verifyChecked //input[@name='UICLVConfigDisplayModeFormRadioBoxInput']
waitForElementPresent //img[@alt='Select folder path']
click //img[@alt='Select folder path']
pause 30000
echo -- Select folder : General Drivers
waitForElementPresent //div[@id='LeftWorkspace']/div[1]/div
click //div[@id='LeftWorkspace']/div[1]/div
echo -- Select Sites Management
waitForElementPresent //a[text()='Sites Management']
click //a[text()='Sites Management']
echo -- Select Sites acme
waitForElementPresent Generaldrives_ManagedSites__acme
click Generaldrives_ManagedSites__acme
echo -- Choose Document
waitForElementPresent //a[@url='/portal/rest/jcr/repository/collaboration/sites content/live/acme/documents']
click //a[@url='/portal/rest/jcr/repository/collaboration/sites content/live/acme/documents']
echo -- verify value in Folder paht
waitForValue UICLVConfigItemPathFormStringInput documents
verifyValue UICLVConfigItemPathFormStringInput documents
waitForElementPresent link=Save
click link=Save
echo -- Press OK in popup
waitForElementPresent //div[@id='UICLVPortlet']//div[@class='ActionButton LightBlueStyle' and contains(@onclick,'javascript:ajaxGet')]
click //div[@id='UICLVPortlet']//div[@class='ActionButton LightBlueStyle' and contains(@onclick,'javascript:ajaxGet')]
waitForElementPresent link=Close
click link=Close
echo Go to "ASnfEcms02" pages : Save
waitForElementPresent //a[@onclick='eXo.core.DOMUtil.disableOnClick(this);']
clickAndWait //a[@onclick='eXo.core.DOMUtil.disableOnClick(this);']
echo Content list
waitForElementPresent link=Where we are
verifyElementPresent link=Where we are
waitForElementPresent link=Conditions and Requirements
verifyElementPresent link=Conditions and Requirements
waitForElementPresent link=How to join us
verifyElementPresent link=How to join us
echo -- Search and delete page: go to Page manage
waitForElementPresent //a[contains(text(),'Page Manager')]
clickAndWait //a[contains(text(),'Page Manager')]
pause 5000
waitForElementPresent searchTerm
type searchTerm ASnfEcms02
select searchOption label=Title
waitForElementPresent //form[@id='UIPageSearch']/div[2]/a
click //form[@id='UIPageSearch']/div[2]/a
pause 5000
waitForElementPresent //img[@title='Delete Page']
click //img[@title='Delete Page']
assertConfirmation Do you want to delete this page?
waitForElementPresent //div[5]/div/div[2]//div[3]//table[@class='ActionContainer']//div[@class='ActionButton LightBlueStyle' and contains(@onclick,'javascript:ajaxGet')]
click //div[5]/div/div[2]//div[3]//table[@class='ActionContainer']//div[@class='ActionButton LightBlueStyle' and contains(@onclick,'javascript:ajaxGet')]
echo -- Delete node
open /portal/private/acme
waitForElementPresent link=Navigation
click link=Navigation
waitForElementPresent //a[@title='ASnfEcms02']
mouseDownRight //a[@title='ASnfEcms02']
click link=Delete Node
assertConfirmation Are you sure you want to delete this node?
waitForElementPresent //div[@id='UINavigationManagement']/div[3]/table/tbody/tr/td[2]/div/div/div/div
click //div[@id='UINavigationManagement']/div[3]/table/tbody/tr/td[2]/div/div/div/div
pause 3000
echo -- Log out
waitForElementPresent link=Logout
clickAndWait link=Logout