Test_SNF_PRL_50_AddApplicationIntoContainerWhenEditPagePropertiesOfNode
open /portal/public/classic
echo -- Change application when edit page properties of node--
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']
echo --Add new node for group --
clickAndWait link=Group
waitForElementPresent link=Edit Navigation
click link=Edit Navigation
waitForElementPresent link=Add Node
click link=Add Node
waitForElementPresent name
type name Test_SNF_PRL_50
type label Test_SNF_PRL_50
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
type //form[@id='UIPageSearchForm']/div[2]/input Community Management
select name=searchOption label=group
waitForElementPresent //a[@title='Quick Search']
click //a[@title='Quick Search']
waitForElementPresent //img[@title='Select Page']
click //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--
clickAndWait link=Test_SNF_PRL_50
waitForTextPresent Test_SNF_PRL_50
verifyTextPresent Test_SNF_PRL_50
echo -- Right click and choose Edit node's page -
waitForElementPresent link=Group
clickAndWait link=Group
waitForElementPresent link=Edit Navigation
click link=Edit Navigation
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_50']
click xpath=//a[@title='Test_SNF_PRL_50']
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_50']
mouseDownRight xpath=//a[@title='Test_SNF_PRL_50']
pause 1000
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 -- Choose Container tab--
waitForElementPresent //div[contains(text(),"Containers")]
click //div[contains(text(),"Containers")]
echo -- Add container by drag & drop--
waitForElementPresent //div[@id='oneRow']/div //div[2]/div/div/div/div/div/div[2]/div/div/div/div/div[1]/div/div/div[1]/div/div/div/div[1]/div
dragAndDropToObject //div[@id='oneRow']/div //div[2]/div/div/div/div/div/div[2]/div/div/div/div/div[1]/div/div/div[1]/div/div/div/div[1]/div
echo -- Choose Application tab--
waitForElementPresent //div[contains(text(),"Applications")]
click //div[contains(text(),"Applications")]
echo -- Drag & drop application into the container added above--
waitForElementPresent link=Gadgets
click link=Gadgets
waitForElementPresent //div[@id='Gadgets/Calculator']/div/div/img //div[2]/div/div/div/div/div/div[2]/div/div/div/div/div[1]/div/div/div[1]/div/div/div
dragAndDropToObject //div[@id='Gadgets/Calculator']/div/div/img //div[2]/div/div/div/div/div/div[2]/div/div/div/div/div[1]/div/div/div[1]/div/div/div
waitForElementPresent link=Switch View mode
click link=Switch View mode
waitForElementPresent UIPortalApplication
verifyElementPresent UIPortalApplication
waitForElementPresent link=Switch View mode
click link=Switch View mode
echo -- Delete application --
mouseOver //div[text()='Calculator']/following-sibling::a[@title='Delete Portlet']
waitForElementPresent //div[text()='Calculator']/following-sibling::a[@title='Delete Portlet']
click //div[text()='Calculator']/following-sibling::a[@title='Delete Portlet']
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete this portlet?
echo -- Choose Container tab to delete container --
waitForElementPresent //div[contains(text(),"Containers")]
click //div[contains(text(),"Containers")]
mouseOver //div[text()='Container']/following-sibling::a[@title='Delete Container']
waitForElementPresent //div[text()='Container']/following-sibling::a[@title='Delete Container']
click //div[text()='Container']/following-sibling::a[@title='Delete Container']
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete this Container?
echo -- Click to Finish
waitForElementPresent //div[@id='UIPageEditor']//a[@title="Finish"]
click //div[@id='UIPageEditor']//a[@title="Finish"]
waitForElementPresent link=Save
click link=Save
echo -- View node --
clickAndWait link=Test_SNF_PRL_50
echo -- Delete this node--
clickAndWait link=Group
waitForElementPresent link=Edit Navigation
click link=Edit Navigation
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_50']
click xpath=//a[@title='Test_SNF_PRL_50']
pause 1000
waitForElementPresent xpath=//a[@title='Test_SNF_PRL_50']
mouseDownRight xpath=//a[@title='Test_SNF_PRL_50']
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_50']
waitForElementPresent link=Save
click link=Save
waitForElementPresent link=Sign out
clickAndWait link=Sign out