Test_SNF_ECMS_29_CreateEditDeletePodcast_ecmdemo
open /ecmdemo/public/acme/
windowMaximize
echo -- Login
waitForElementPresent link=Login
click link=Login
waitForElementPresent username
type username root
type password gtn
clickAndWait link=Sign in
echo -- Go to Sites Explorer
clickAndWait link=Sites Explorer
echo --Open  driver pane
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 --Open Private driver
waitForElementPresent link=Private
click link=Private
echo --Go to Detail View
waitForElementPresent //form[@id='UIAddressBar']/div[2]/table/tbody/tr/td[1]/a
click //form[@id='UIAddressBar']/div[2]/table/tbody/tr/td[1]/a
echo -- Go to Action tab
pause 3000
waitForElementPresent //a[contains(text(),'Actions')]
click //a[contains(text(),'Actions')]
pause 3000
echo --Add Podcast
waitForElementPresent link=Add Document
click link=Add Document
waitForElementPresent selectTemplate label=Podcast
select selectTemplate label=Podcast
waitForElementPresent name
type name Podcast
type title Titile
type link google.com
type author Dung
waitForElementPresent link=Save as Draft
click link=Save as Draft
pause 5000
waitForElementPresent link=Close
click link=Close
pause 5000
echo --Edit Podcast
waitForElementPresent link=Podcast
click link=Podcast
waitForElementPresent link=Edit Document
click link=Edit Document
waitForElementPresent description test
type description test
waitForElementPresent link=Save as Draft
click link=Save as Draft
pause 5000
waitForElementPresent link=Close
click link=Close
echo --Delete
waitForElementPresent link=Podcast
mouseDownRight link=Podcast
waitForElementPresent link=Delete
click link=Delete
waitForElementPresent //div/div[2]/table/tbody/tr/td/div[1]/div/div/div/a
click //div/div[2]/table/tbody/tr/td/div[1]/div/div/div/a
pause 3000
waitForElementNotPresent link=Podcast
verifyElementNotPresent link=Podcast
echo -- Log out
waitForElementPresent link=Sign out
clickAndWait link=Sign out