Test_SNF_KS_25_ksdemo_BasicActionsInForum
open /ksdemo/public/classic/
windowMaximize
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //a[@id='UIPortalLoginFormAction']
echo -Add Category for Test-
open /ksdemo/private/classic/forum
waitForElementPresent link=Add Category
click link=Add Category
waitForElementPresent CategoryTitle
type CategoryTitle Cate1_SNF_KS_25
type Description Category 1
waitForElementPresent link=Save
click link=Save
waitForElementPresent //div[@id='UIBreadcumbs']//a[@title='Home']
click //div[@id='UIBreadcumbs']//a[@title='Home']
waitForTextPresent Cate1_SNF_KS_25
verifyTextPresent Cate1_SNF_KS_25
waitForElementPresent link=Add Category
click link=Add Category
waitForElementPresent CategoryTitle
type CategoryTitle Cate2_SNF_KS_25
type Description Category 2
waitForElementPresent link=Save
click link=Save
waitForElementPresent //div[@id='UIBreadcumbs']//a[@title='Home']
click //div[@id='UIBreadcumbs']//a[@title='Home']
waitForTextPresent Cate2_SNF_KS_25
verifyTextPresent Cate2_SNF_KS_25
echo -Add Forum-
click link=Cate1_SNF_KS_25
waitForElementPresent //a[contains(text(),'Add Forum')]
click //a[contains(text(),'Add Forum')]
waitForElementPresent ForumTitle
type ForumTitle For_SNF_KS_25
type Description Forum actions
waitForElementPresent //form[@id='UIForumForm']//a[text()='Save']
click //form[@id='UIForumForm']//a[text()='Save']
waitForTextPresent For_SNF_KS_25
verifyTextPresent For_SNF_KS_25
echo -Edit Forum-
waitForElementPresent //a[contains(text(),'More Actions')]
click //a[contains(text(),'More Actions')]
waitForElementPresent //form[@id='UITopicContainer']/div[4]/div[1]/div[3]/div[2]/ul/li[2]/a
click //form[@id='UITopicContainer']/div[4]/div[1]/div[3]/div[2]/ul/li[2]/a
waitForElementPresent ForumTitle
verifyValue ForumTitle For_SNF_KS_25
verifyValue Description Forum actions
type ForumTitle For_SNF_KS_25_Update
type Description Forum actions Update
waitForElementPresent link=Save
click link=Save
waitForElementPresent UITopicContainer
verifyElementPresent //div[@id='UIForumDescription']//span[text()='For_SNF_KS_25_Update'] For_SNF_KS_25_Update
waitForElementPresent //div[@id='UIForumDescription']//span[text()=': Forum actions Update']
verifyElementPresent //div[@id='UIForumDescription']//span[text()=': Forum actions Update'] Forum actions Update
echo -Move Forum-
waitForElementPresent //a[contains(text(),'More Actions')]
click //a[contains(text(),'More Actions')]
waitForElementPresent //form[@id='UITopicContainer']//a[contains(@href,'MoveForum')]
click //form[@id='UITopicContainer']//a[contains(@href,'MoveForum')]
waitForTextPresent Cate2_SNF_KS_25
waitForElementPresent //form[@id='UIMoveForumForm']//a[contains(text(),'Cate2_SNF_KS_25')]
click //form[@id='UIMoveForumForm']//a[contains(text(),'Cate2_SNF_KS_25')]
waitForTextPresent Cate2_SNF_KS_25
click link=Cate2_SNF_KS_25
waitForElementPresent link=For_SNF_KS_25_Update
verifyElementPresent link=For_SNF_KS_25_Update
echo -Delete Forum-
waitForElementPresent link=For_SNF_KS_25_Update
click link=For_SNF_KS_25_Update
waitForElementPresent //a[contains(text(),'More Actions')]
click //a[contains(text(),'More Actions')]
waitForElementPresent //form[@id='UITopicContainer']//a[contains(@href,'RemoveForum')]
click //form[@id='UITopicContainer']//a[contains(@href,'RemoveForum')]
assertConfirmation Are you sure to delete this forum?
waitForTextNotPresent Test Forum Actions
verifyTextNotPresent Test Forum Actions
waitForElementPresent //div[@id='UIBreadcumbs']//a[@title='Home']
click //div[@id='UIBreadcumbs']//a[@title='Home']
waitForElementPresent link=Cate1_SNF_KS_25
click link=Cate1_SNF_KS_25
waitForElementPresent link=Manage Category
click link=Manage Category
waitForElementPresent link=Delete
click link=Delete
assertConfirmation Are you sure to delete this category?
waitForElementNotPresent link=Cate1_SNF_KS_25
verifyTextNotPresent link=Cate1_SNF_KS_25
waitForElementPresent link=Cate2_SNF_KS_25
click link=Cate2_SNF_KS_25
waitForElementPresent link=Manage Category
click link=Manage Category
waitForElementPresent link=Delete
click link=Delete
assertConfirmation Are you sure to delete this category?
waitForElementNotPresent link=Cate2_SNF_KS_25
verifyTextNotPresent link=Cate2_SNF_KS_25
waitForElementPresent link=Sign out
clickAndWait link=Sign out
waitForTextPresent Sign in