Test_ANS_35_010
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 Ordered list tag
waitForElementPresent QuestionTitle
type QuestionTitle Question Test_ANS_35_010
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 Ordered list effect
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_010
click link=Question Test_ANS_35_010
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: [list=1] [*]Go to the shops [*]Buy a new computer [*]Swear at computer when it crashes [/list] or [list=a] [*]The first possible answer [*]The second possible answer [*]The third possible answer [/list]
selectFrame relative=top
waitForElementPresent link=Save
clickAt link=Save 1,1
waitForAttribute //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol@type 1
verifyAttribute //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol@type 1
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[1]/li[1] Go to the shops
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[1]/li[2] Buy a new computer
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[1]/li[3] Swear at computer when it crashes
waitForAttribute //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[2]@type a
verifyAttribute //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[2]@type a
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[2]/li[1] The first possible answer
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[2]/li[2] The second possible answer
verifyText //div[@id='SetWidthContent']/div/div/table/tbody/tr/td[1]/div[2]/div[1]/div[1]/ol[2]/li[3] The third possible answer
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_010
mouseOver link=Question Test_ANS_35_010
contextMenu link=Question Test_ANS_35_010
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_010
verifyTextNotPresent Test_ANS_35_010
waitForElementPresent link=Sign out
clickAndWait link=Sign out