2020-01-26 13:19:35 +00:00
|
|
|
<?php declare(strict_types=1);
|
2020-01-28 21:19:59 +00:00
|
|
|
class EmoticonsTest extends ShimmiePHPUnitTestCase
|
2019-05-28 17:59:38 +01:00
|
|
|
{
|
|
|
|
public function testEmoticons()
|
|
|
|
{
|
|
|
|
global $user;
|
2015-09-12 12:24:18 +01:00
|
|
|
|
2019-05-28 17:59:38 +01:00
|
|
|
$this->log_in_as_user();
|
|
|
|
$image_id = $this->post_image("tests/pbx_screenshot.jpg", "pbx computer screenshot");
|
2009-07-20 06:51:36 +01:00
|
|
|
|
2019-05-28 17:59:38 +01:00
|
|
|
send_event(new CommentPostingEvent($image_id, $user, ":cool: :beans:"));
|
2015-09-12 12:24:18 +01:00
|
|
|
|
2019-05-28 17:59:38 +01:00
|
|
|
$this->get_page("post/view/$image_id");
|
|
|
|
$this->assert_no_text(":cool:"); # FIXME: test for working image link
|
|
|
|
//$this->assert_text(":beans:"); # FIXME: this should be left as-is
|
2009-07-20 06:51:36 +01:00
|
|
|
|
2019-05-28 17:59:38 +01:00
|
|
|
$this->get_page("emote/list");
|
|
|
|
//$this->assert_text(":arrow:");
|
|
|
|
}
|
2009-07-20 06:51:36 +01:00
|
|
|
}
|