Test_ANS_35_013
open /ksdemo/public/classic/
windowMaximize
echo Step 1: Login and Open Answers application
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username demo
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
echo Step 2: Open Submit question form
waitForElementPresent //div[@id='PortalNavigationTopContainer']/div[4]/div/div/div/div/div/div/a
clickAndWait //div[@id='PortalNavigationTopContainer']/div[4]/div/div/div/div/div/div/a
waitForElementPresent link=Submit question
click link=Submit question
echo Step 3: Compose question with Image tag
waitForElementPresent QuestionTitle
type QuestionTitle Question Test_ANS_35_013
selectFrame //*[@id="Question___Frame"]
waitForElementPresent //html/body/table/tbody/tr[2]/td/iframe
selectFrame //html/body/table/tbody/tr[2]/td/iframe
waitForElementPresent //html/body
type //html/body Check Adding image to a post
selectFrame relative=top
type EmailAddress demo@localhost.com
waitForElementPresent link=Save
clickAt link=Save 1,1
echo confirm OK
waitForElementPresent //div[3]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div/a
clickAt //div[3]/div/div[2]/div/div/div/div/div/div[3]/div/table/tbody/tr/td/div/div/div/div/a 1,1
waitForElementPresent link=Question Test_ANS_35_013
click link=Question Test_ANS_35_013
waitForElementPresent link=Answer
click link=Answer
waitForElementPresent //*[@id="QuestionRespone___Frame"]
selectFrame //*[@id="QuestionRespone___Frame"]
waitForElementPresent //html/body/table/tbody/tr[2]/td/iframe
selectFrame //html/body/table/tbody/tr[2]/td/iframe
waitForElementPresent //html/body
type //html/body For example: [img]http://www.google.com/intl/en_ALL/images/logo.gif[/img]
selectFrame relative=top
waitForElementPresent link=Save
clickAt link=Save 1,1
waitForElementPresent //img[contains(@src,'http://www.google.com/intl/en_ALL/images/logo.gif')]
verifyElementPresent //img[contains(@src,'http://www.google.com/intl/en_ALL/images/logo.gif')]
verifyAttribute //p/img@src http://www.google.com/intl/en_ALL/images/logo.gif
echo =======detele data
waitForElementPresent link=Sign out
clickAndWait link=Sign out
waitForElementPresent link=Sign in
click link=Sign in
waitForElementPresent username
type username root
type password gtn
clickAndWait //div[@id='UIPortalLoginFormAction']/div/div/div/a
waitForElementPresent //div[@id='PortalNavigationTopContainer']/div[4]/div/div/div/div/div/div/a
clickAndWait //div[@id='PortalNavigationTopContainer']/div[4]/div/div/div/div/div/div/a
waitForElementPresent link=Question Test_ANS_35_013
mouseOver link=Question Test_ANS_35_013
contextMenu link=Question Test_ANS_35_013
waitForElementPresent //div[@id='UIPopupQuestion0']/div/div/div/div/div[4]/a
click //div[@id='UIPopupQuestion0']/div/div/div/div/div[4]/a
waitForElementPresent //form[@id='UIDeleteQuestion']/div[3]/table/tbody/tr/td/div[1]/div/div/div/a
clickAt //form[@id='UIDeleteQuestion']/div[3]/table/tbody/tr/td/div[1]/div/div/div/a 1,1
waitForTextNotPresent Test_ANS_35_013
verifyTextNotPresent Test_ANS_35_013
waitForElementPresent link=Sign out
clickAndWait link=Sign out