handle test error

This commit is contained in:
Shish 2012-03-12 23:27:24 +00:00
parent a5ba9279c4
commit 4b59c79fed

View file

@ -10,8 +10,10 @@ class LinkImageTest extends ShimmieWebTestCase {
$matches = array();
preg_match("#value='(http://.*(/|%2F)post(/|%2F)view(/|%2F)[0-9]+)'#", $raw, $matches);
$this->assertTrue(count($matches) > 0);
$this->get($matches[1]);
$this->assert_title("Image $image_id: pie");
if($matches) {
$this->get($matches[1]);
$this->assert_title("Image $image_id: pie");
}
$this->log_out();