diff options
author | Marc Alexander <admin@m-a-styles.de> | 2013-07-22 13:38:19 +0200 |
---|---|---|
committer | Marc Alexander <admin@m-a-styles.de> | 2013-07-22 13:38:19 +0200 |
commit | 2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8 (patch) | |
tree | 8d68c3141aa4e8287527baf04dd5b0a76f72798c /tests/functional/avatar_ucp_users_test.php | |
parent | e48f0555e9e40a9e1d3e9a60e25a9f206c565efe (diff) | |
download | forums-2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8.tar forums-2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8.tar.gz forums-2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8.tar.bz2 forums-2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8.tar.xz forums-2eb32ef515c59b19bd1bb4f7e6d56736733ea9d8.zip |
[ticket/11531] Check if uploaded avatar is properly displayed in tests
PHPBB3-11531
Diffstat (limited to 'tests/functional/avatar_ucp_users_test.php')
-rw-r--r-- | tests/functional/avatar_ucp_users_test.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/functional/avatar_ucp_users_test.php b/tests/functional/avatar_ucp_users_test.php index fa6282abf4..f828559e0d 100644 --- a/tests/functional/avatar_ucp_users_test.php +++ b/tests/functional/avatar_ucp_users_test.php @@ -59,4 +59,20 @@ class phpbb_functional_avatar_ucp_users_test extends phpbb_functional_common_ava { $this->assert_avatar_submit($expected, $avatar_type, $data); } + + public function test_display_upload_avatar() + { + $this->assert_avatar_submit('PROFILE_UPDATED', + 'avatar_driver_upload', + array( + 'avatar_upload_url' => 'https://secure.gravatar.com/avatar/55502f40dc8b7c769880b10874abc9d0.jpg', + ) + ); + + $crawler = self::request('GET', $this->get_url() . '&sid=' . $this->sid); + $avatar_link = $crawler->filter('img')->attr('src'); + $crawler = self::request('GET', $avatar_link . '&sid=' . $this->sid, array(), false); + $content = self::$client->getResponse()->getContent(); + self::assertEquals(false, stripos(trim($content), 'debug'), 'Output contains debug message'); + } } |