Test_REG_DMS_DMS004_VoteForFreeLayoutWebcontent
open /ecmdemo/public/acme/
windowMaximize
echo -- Login
click link=Login
waitForElementPresent username
type username root
type password gtn
clickAndWait link=Sign in
echo -- Go to Site Explorer
clickAndWait link=Content Explorer
echo -- Open drive's list
waitForElementPresent //div[@id='UISideBar']/div/div[1]/div[2]/div[1]/div/div/div/a/div
click //div[@id='UISideBar']/div/div[1]/div[2]/div[1]/div/div/div/a/div
echo -- Select Site Management drive
waitForElementPresent link=Sites Management
click link=Sites Management
echo -- Select acme folder
waitForElementPresent //div[@id='iconTreeExplorer']/div[2]/a
click //div[@id='iconTreeExplorer']/div[2]/a
echo -- Select web content folder
waitForElementPresent link=web contents
click link=web contents
echo -- Create free layout webcontent
waitForElementPresent link=Add Document
click link=Add Document
waitForElementPresent title DMS004
type title DMS004
waitForElementPresent //td[contains(@id,'cke_contents_htmlData')]/iframe
selectFrame //td[contains(@id,'cke_contents_htmlData')]/iframe
type //html/body test vote for free layout web content
selectFrame relative=top
waitForElementPresent //form[@id='UIDocumentForm']/div[2]/div/div[2]/div[2]/table/tbody/tr/td/a[1]/div/div/div
click //form[@id='UIDocumentForm']/div[2]/div/div[2]/div[2]/table/tbody/tr/td/a[1]/div/div/div
pause 3000
waitForElementPresent //form[@id='UIDocumentForm']/div[2]/div/div[2]/div[2]/table/tbody/tr/td/a[2]/div/div/div
click //form[@id='UIDocumentForm']/div[2]/div/div[2]/div[2]/table/tbody/tr/td/a[2]/div/div/div
pause 3000
echo -- Vote for document
waitForElementPresent link=Collaboration
click link=Collaboration
waitForElementPresent link=Vote for document
click link=Vote for document
waitForElementPresent //div[@id='UIVoteForm']/div/div[1]/div/div[4]
click //div[@id='UIVoteForm']/div/div[1]/div/div[4]
waitForTextPresent 4.0
verifyTextPresent 4.0
echo -- Delete document
waitForElementPresent link=DMS004
mouseDownRight link=DMS004
waitForElementPresent link=Delete
click link=Delete
waitForElementPresent //div[@id='UIPopupWindow']/div/div[2]/div/div/div/div/div/div/div/div[2]/table/tbody/tr/td/div[1]/div/div/div/a
click //div[@id='UIPopupWindow']/div/div[2]/div/div/div/div/div/div/div/div[2]/table/tbody/tr/td/div[1]/div/div/div/a
echo -- Log out
clickAndWait link=Sign out