Test_POR_14_04_002_CutPasteNodeToTheSameNavigation
open /portal/public/classic/
echo --Login portal--
windowMaximize
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
echo --Open Navigation Menu--
waitForElementPresent link=Site
click link=Site
waitForElementPresent link=Edit Navigation
click link=Edit Navigation
echo --Add a node--
waitForElementPresent link=Add Node
click link=Add Node
waitForElementPresent name
type name Test_POR_14_04_002
type label Test_POR_14_04_002
echo -- Choose Page Selector--
waitForElementPresent //div[2]/div/div/div/div/div/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div
click //div[2]/div/div/div/div/div/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div
waitForElementPresent //div[@id='UIPageSelector2']/div[3]/table/tbody/tr/td/div[3]/div/div/div/div
click //div[@id='UIPageSelector2']/div[3]/table/tbody/tr/td/div[3]/div/div/div/div
waitForElementPresent //img[@title='Select Page']
click //img[@title='Select Page']
waitForElementPresent link=Save
click link=Save
echo -- Copy node--
waitForElementPresent link=Test_POR_14_04_002
click link=Test_POR_14_04_002
waitForElementPresent //a[@class='NodeIcon DefaultPageIcon NodeSelected' and @title='Test_POR_14_04_002']
mouseDownRight //a[@class='NodeIcon DefaultPageIcon NodeSelected' and @title='Test_POR_14_04_002']
click link=Copy Node
echo -- Paste node to same navigation--
click //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[2]/div/a
waitForElementPresent //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[2]/div/a
mouseDownRight //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[2]/div/a
waitForElementPresent //div[@id='NavigationNodePopupMenu']/div/div[2]/div/div/div[7]/a
click //div[@id='NavigationNodePopupMenu']/div/div[2]/div/div/div[7]/a
waitForElementPresent link=Save
click link=Save
waitForElementPresent //div[@id='PortalNavigationTopContainer']/div[3]/div/div/div/div/div/div/a
click //div[@id='PortalNavigationTopContainer']/div[3]/div/div/div/div/div/div/a Test_POR_14_04_002
echo -- Delete node--
waitForElementPresent link=Site
clickAndWait link=Site
waitForElementPresent link=Edit Navigation
click link=Edit Navigation
waitForElementPresent //div[2]/div/div/div[2]/div[2]/div/div/a
mouseDownRight //div[@id='UINavigationNodeSelector']/div/div/div/div[2]/div/div/div[2]/div[2]/div/div/a Test_POR_14_04_002
waitForElementPresent link=Delete Node
click link=Delete Node
assertConfirmation Are you sure you want to delete this node?
waitForElementPresent //div[8]/div/a
mouseDownRight //div[8]/div/a Test_POR_14_04_002
waitForElementPresent link=Delete Node
click link=Delete Node
assertConfirmation Are you sure you want to delete this node?
waitForElementPresent link=Save
click link=Save
clickAndWait link=Sign out