Test_SNF_PRL_27_AddApplicationIntoContainerInLayoutOfPortal
open /portal/classic/
echo -- Add application into container in layout of portal--
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']
clickAndWait link=Site
echo -- Click Edit layout--
waitForElementPresent //a[contains(@href,'classic')]/preceding-sibling::a[text()='Edit Layout']
click //a[contains(@href,'classic')]/preceding-sibling::a[text()='Edit Layout']
waitForElementPresent link=Switch View Mode
click link=Switch View Mode
waitForElementNotPresent css=div[class='LAYOUT-PORTAL LAYOUT-BLOCK']
verifyElementNotPresent css=div[class='LAYOUT-PORTAL LAYOUT-BLOCK']
waitForElementPresent link=Switch View Mode
click link=Switch View Mode
echo -- Choose Container tab--
waitForElementPresent //div[@id='UIPortalComposerTab']//div[contains(text(),"Containers")]
click //div[@id='UIPortalComposerTab']//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[@id='UIPortalComposerTab']//div[contains(text(),"Applications")]
click //div[@id='UIPortalComposerTab']//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
click link=Switch View Mode
waitForElementPresent css=div[class='VIEW-PORTAL VIEW-BLOCK']
verifyElementPresent css=div[class='VIEW-PORTAL VIEW-BLOCK']
click link=Switch View Mode
echo -- Delete application --
mouseOver //div[@title="Hold this area to drag this portlet"] Calculator
waitForElementPresent //a[@title="Delete Portlet"]
click //a[@title="Delete Portlet"]
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete this portlet?
echo -- Choose Container tab to delete container --
waitForElementPresent //div[@id='UIPortalComposerTab']//div[contains(text(),"Containers")]
click //div[@id='UIPortalComposerTab']//div[contains(text(),"Containers")]
mouseOver //div[@title="Hold this area to drag this container"] Container
waitForElementPresent //a[@title="Delete Container"]
click //a[@title="Delete Container"]
waitForConfirmationPresent
assertConfirmation Are you sure you want to delete this Container?
echo -- Click to Finish
waitForElementPresent //div[@id='UIPortalComposer']//a[@title="Finish"]
click //div[@id='UIPortalComposer']//a[@title="Finish"]
waitForElementPresent link=Sign out
clickAndWait link=Sign out