aboutsummaryrefslogtreecommitdiffstats
path: root/tests/functional
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2015-06-16 14:34:44 +0200
committerAndreas Fischer <bantu@phpbb.com>2015-06-16 14:34:44 +0200
commitbeb830df712e74107d3f50f094ac143a1d812efc (patch)
tree39036b84b25ca95cfe7a38d98ce649d2b63911c4 /tests/functional
parent65fef50869a8b16635f24e324ce7820509ef4aa5 (diff)
parent78eeb210e78429d867347ecb7c0eedf707005632 (diff)
downloadforums-beb830df712e74107d3f50f094ac143a1d812efc.tar
forums-beb830df712e74107d3f50f094ac143a1d812efc.tar.gz
forums-beb830df712e74107d3f50f094ac143a1d812efc.tar.bz2
forums-beb830df712e74107d3f50f094ac143a1d812efc.tar.xz
forums-beb830df712e74107d3f50f094ac143a1d812efc.zip
Merge pull request #3675 from s9e/ticket/13906
[ticket/13906] Fixed old signatures in post preview * s9e/ticket/13906: [ticket/13906] Renamed test [ticket/13906] Added test [ticket/13906] Fixed old signatures in post preview
Diffstat (limited to 'tests/functional')
-rw-r--r--tests/functional/posting_test.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/functional/posting_test.php b/tests/functional/posting_test.php
index 49f0c1d749..ccfeb10deb 100644
--- a/tests/functional/posting_test.php
+++ b/tests/functional/posting_test.php
@@ -180,4 +180,26 @@ class phpbb_functional_posting_test extends phpbb_functional_test_case
$crawler = self::submit($form);
$this->assertEquals($text, $crawler->filter('#message')->text());
}
+
+ public function test_old_signature_in_preview()
+ {
+ $sql = 'UPDATE ' . USERS_TABLE . "
+ SET user_sig = '[b:2u8sdcwb]My signature[/b:2u8sdcwb]',
+ user_sig_bbcode_uid = '2u8sdcwb',
+ user_sig_bbcode_bitfield = 'QA=='
+ WHERE user_id = 2";
+ $this->get_db()->sql_query($sql);
+
+ $this->login();
+ $crawler = self::request('GET', 'posting.php?mode=post&f=2');
+ $form = $crawler->selectButton('Preview')->form(array(
+ 'subject' => 'Test subject',
+ 'message' => 'My post',
+ ));
+ $crawler = self::submit($form);
+ $this->assertContains(
+ '<span style="font-weight: bold">My signature</span>',
+ $crawler->filter('#preview .signature')->html()
+ );
+ }
}