test source editing

This commit is contained in:
Shish 2010-03-08 21:23:16 +00:00
parent e7cbb00191
commit f42468e6eb

View file

@ -21,5 +21,30 @@ class TagEditTest extends ShimmieWebTestCase {
# FIXME: test mass tag editor
}
function testSourceEdit() {
$this->log_in_as_user();
$image_id = $this->post_image("ext/simpletest/data/pbx_screenshot.jpg", "pbx");
$this->get_page("post/view/$image_id");
$this->assert_title("Image $image_id: pbx");
$this->set_field("tag_edit__source", "example.com");
$this->click("Set");
$this->click("Source");
$this->assert_title("Example Web Page");
$this->back();
$this->set_field("tag_edit__source", "http://example.com");
$this->click("Set");
$this->click("Source");
$this->assert_title("Example Web Page");
$this->back();
$this->log_out();
$this->log_in_as_admin();
$this->delete_image($image_id);
$this->log_out();
}
}
?>