TestEditPost
open /wp-admin/
clickAndWait link=Add New
assertElementPresent //script[contains(@src, 'prototype')]
assertElementPresent //script[contains(@src, 'effects')]
assertElementPresent //script[contains(@src, 'builder')]
click //div[@id='comic-for-this-post']//input[@type="radio"][1]
storeAttribute //div[@id='comic-for-this-post']//input[@type="radio"][1]@value category
assertNotChecked //div[@id='categories-all']//input[@value='1']
type title Selenium Test
click save-post
waitForPageToLoad 50000
assertChecked //div[@id='categories-all']//input[@value='${category}']
assertNotChecked //div[@id='categories-all']//input[@value='1']
clickAndWait link=Move to Trash
assertTextPresent Post moved to the trash.
clickAndWait //a[@href='post-new.php']
type title Selenium Test
type comicpress-replace-image /home/john/Desktop/comicpress/selenium/1990-01-01-sample-comic.jpeg
fireEvent comicpress-replace-image click
clickAndWait publish
assertTextPresent Post published. View post
assertValue title Selenium Test
assertChecked post_category-3
assertTextPresent sample-comic.jpeg
click //a[contains(@class, 'edit-slug')]
type new-post-slug my-test-permalink
click link=OK
clickAndWait publish
assertValue title Selenium Test
assertChecked post_category-3
assertTextPresent sample-comic.jpeg
click link=Move to Trash
waitForPageToLoad 30000
assertTextPresent moved to the trash.