Test_SNF_KS_30_ksdemo_TagTopic
open /portal/public/intranet/
windowMaximize
waitForElementPresent //div[contains(text(),'Sign in')]
click //div[contains(text(),'Sign in')]
waitForElementPresent username
type username root
waitForElementPresent password
type password gtn
clickAndWait //a[@id='UIPortalLoginFormAction']
open /portal/private/intranet/forum
echo -Add Category for Test-
waitForElementPresent link=Add Category
click link=Add Category
waitForElementPresent CategoryTitle
type CategoryTitle Cate1_SNF_KS_30
type Description Category 1
click link=Save
waitForTextPresent Cate1_SNF_KS_30
verifyTextPresent Cate1_SNF_KS_30
echo -Add Forum-
waitForElementPresent //a[contains(text(),'Add Forum')]
click //a[contains(text(),'Add Forum')]
waitForElementPresent ForumTitle
type ForumTitle For1_SNF_KS_30
type Description prepare forum data
waitForElementPresent //form[@id='UIForumForm']//a[text()='Save']
click //form[@id='UIForumForm']//a[text()='Save']
waitForElementPresent link=Cate1_SNF_KS_30
click link=Cate1_SNF_KS_30
waitForTextPresent For1_SNF_KS_30
verifyTextPresent For1_SNF_KS_30
echo -Add topic-
waitForElementPresent link=For1_SNF_KS_30
click link=For1_SNF_KS_30
waitForElementPresent //a[contains(text(),'Start Topic')]
click //a[contains(text(),'Start Topic')]
waitForElementPresent ThreadTitle
type ThreadTitle Top1_SNF_KS_30
waitForElementPresent //iframe[@id='messageContent___Frame']
selectFrame //iframe[@id='messageContent___Frame']
selectFrame //html/body/table/tbody/tr[2]/td/iframe
type //html/body topic1 for tag
selectFrame relative=top
waitForElementPresent link=Submit
click link=Submit
waitForTextPresent Top1_SNF_KS_30
verifyTextPresent Top1_SNF_KS_30
echo --Add tag for topic
waitForElementPresent link=Top1_SNF_KS_30
click link=Top1_SNF_KS_30
waitForElementPresent link=Tag
click link=Tag
type AddTag toto titi tata
waitForElementPresent //div[@id='AddTagId']//div[contains(text(),'Add Tag')]
click //div[@id='AddTagId']//div[contains(text(),'Add Tag')]
waitForElementPresent link=toto
verifyElementPresent link=toto
verifyElementPresent link=titi
verifyElementPresent link=tata
echo -- Untag from Manage tag
waitForElementPresent link=toto
click link=toto
waitForElementPresent //div[@id='UITopicContent']/table/tbody/tr/td[9]/input
click //div[@id='UITopicContent']/table/tbody/tr/td[9]/input
waitForElementPresent link=Manage Tag
click link=Manage Tag
waitForElementPresent link=Untag
click link=Untag
assertConfirmation Are you sure to remove this tag from the topic?
echo -- Untag by click on icon
waitForElementPresent link=Top1_SNF_KS_30
click link=Top1_SNF_KS_30
waitForElementPresent //ul[@id='TagContainer']//span[@title='Untag this topic.']
click //ul[@id='TagContainer']//span[@title='Untag this topic.']
echo --Check existing of tag in topic after untag
waitForTextNotPresent toto
verifyTextNotPresent toto
waitForTextNotPresent titi
verifyTextNotPresent titi
echo -Delete Test Data
waitForElementPresent link=Cate1_SNF_KS_30
click link=Cate1_SNF_KS_30
waitForElementPresent link=Manage Category
click link=Manage Category
waitForElementPresent link=Delete
click link=Delete
assertConfirmation Are you sure to delete this category?
waitForTextNotPresent Cate1_SNF_KS_30
verifyTextNotPresent Cate1_SNF_KS_30
waitForElementPresent link=Logout
clickAndWait link=Logout
waitForTextPresent Sign in