Test_SNF_PRL_35_ChangeApplicationWhenEditPropertiesOfNodeInPortalNavigation
open /portal/classic
echo -- Edit Node page's properties in portal navigation--
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']
echo --Add new node for portal --
clickAndWait link=Site
waitForElementPresent //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
click //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
waitForElementPresent link=Add Node
click link=Add Node
waitForElementPresent name
type name Test_SNF_PRL_35
type label Test_SNF_PRL_35
echo -- Page Selector--
waitForElementPresent //div[text()='Page Selector']
click //div[text()='Page Selector']
waitForElementPresent link=Search and Select Page
click link=Search and Select Page
waitForElementPresent //form[@id='UIPageSearchForm']/div[2]/input
type //form[@id='UIPageSearchForm']/div[2]/input Community Management
waitForElementPresent searchOption
select searchOption label=group
waitForElementPresent //a[@title='Quick Search']
click //a[@title='Quick Search']
waitForElementPresent xpath=//img[@title='Select Page']
click xpath=//img[@title='Select Page']
waitForElementPresent link=Save
click link=Save
echo -- Save to finish create new node--
waitForElementPresent link=Save
click link=Save
echo -- View new node--
waitForTextPresent Test_SNF_PRL_35
verifyTextPresent Test_SNF_PRL_35
echo -- Change application when edit page properties of node --
clickAndWait link=Site
waitForElementPresent //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
click //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
waitForElementPresent //a[@title='Test_SNF_PRL_35']
click //a[@title='Test_SNF_PRL_35']
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_35']
mouseDownRight xpath=//a[@title='Test_SNF_PRL_35']
waitForElementPresent link=Edit Node's Page
click link=Edit Node's Page
echo -- View layout of node before Change application--
waitForElementPresent link=Switch View mode
click link=Switch View mode
waitForTextPresent User Management
verifyTextPresent User Management
waitForTextPresent Group Management
verifyTextPresent Group Management
waitForTextPresent Membership Management
verifyTextPresent Membership Management
waitForElementPresent link=Switch View mode
click link=Switch View mode
echo -- Drag & drop applcation in portal--
waitForElementPresent link=Gadgets
click link=Gadgets
waitForElementPresent //div[@id='Gadgets/Calculator']/div/div/div[1]/div[1] UIPortalApplication
dragAndDropToObject //div[@id='Gadgets/Calculator']/div/div/div[1]/div[1] UIPortalApplication
echo -- View application after drag & drop in portal--
waitForElementPresent link=Switch View mode
click link=Switch View mode
waitForTextPresent User Management
verifyTextPresent User Management
waitForTextPresent Group Management
verifyTextPresent Group Management
waitForTextPresent Membership Management
verifyTextPresent Membership Management
echo -- Return to normal view --
waitForElementPresent link=Switch View mode
click link=Switch View mode
echo --Edit application --
mouseOver //div[text()='Calculator']/following-sibling::a[@title='Edit Portlet']
waitForElementPresent //div[text()='Calculator']/following-sibling::a[@title='Edit Portlet']
click //div[text()='Calculator']/following-sibling::a[@title='Edit Portlet']
waitForElementPresent title
type title Test_SNF_PRL_35
echo -- Choose Select Icon tab --
waitForElementPresent //div[@id='UIMaskWorkspace']//div[text()="Select Icon"]
click //div[@id='UIMaskWorkspace']//div[text()="Select Icon"]
waitForElementPresent //form[@id='UIPortletForm']/div[3]/div/div/div[2]/div[2]/div/a[1]/div
click //form[@id='UIPortletForm']/div[3]/div/div/div[2]/div[2]/div/a[1]/div
echo -- Choose Decoration Themes--
waitForElementPresent //div[@id='UIMaskWorkspace']//div[text()="Decoration Themes"]
click //div[@id='UIMaskWorkspace']//div[text()="Decoration Themes"]
waitForElementPresent //div[text()='Pink Simple']
click //div[text()='Pink Simple']
waitForElementPresent link=Save And Close
click link=Save And Close
echo -- View after change something in application --
waitForElementPresent link=Switch View mode
click link=Switch View mode
waitForElementPresent //div[@class='PortletIcon AcrobatFile']
verifyElementPresent //div[@class='PortletIcon AcrobatFile'] Test_SNF_PRL_35
echo -- Return to normail view --
waitForElementPresent link=Switch View mode
click link=Switch View mode
echo -- Move position of application --
mouseOver //div[@title="Hold this area to drag this portlet"]
dragAndDropToObject //div[@title="Hold this area to drag this portlet"] //div[contains(text(),"Test_SNF_PRL_35")]
echo -- View after change position of application --
waitForElementPresent link=Switch View mode
click link=Switch View mode
waitForElementPresent UIPortalApplication
click UIPortalApplication
waitForElementPresent link=Switch View mode
click link=Switch View mode
echo -- Delete application --
mouseOver //div[text()='Test_SNF_PRL_35']/following-sibling::a[@title='Delete Portlet']
waitForElementPresent //div[text()='Test_SNF_PRL_35']/following-sibling::a[@title='Delete Portlet']
click //div[text()='Test_SNF_PRL_35']/following-sibling::a[@title='Delete Portlet']
waitForConfirmationPresent
assertConfirmation Are you sure to delete this portlet?
waitForElementPresent //div[@id='UIPageEditor']//a[@title='Finish']
click //div[@id='UIPageEditor']//a[@title='Finish']
echo -- Close Navigation Management form --
waitForElementPresent link=Save
click link=Save
echo -- View node after change application --
clickAndWait //div[3]/div/div/div/div/div/div/a
echo -- Delete this node--
clickAndWait link=Site
waitForElementPresent //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
click //div[@id='UISiteManagement']//a[contains(@href,"classic") and text()="Edit Navigation"]
waitForElementPresent //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[8]/div/a
click //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[8]/div/a
pause 1000
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_35']
mouseDownRight xpath=//a[@title='Test_SNF_PRL_35']
waitForElementPresent link=Delete Node
click link=Delete Node
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete this node?
waitForElementNotPresent xpath=//a[@title='Test_SNF_PRL_35']
waitForElementPresent link=Save
click link=Save
waitForElementPresent link=Sign out
clickAndWait link=Sign out