mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-07 19:24:28 +02:00
Add test
This commit is contained in:
parent
403b0672e6
commit
3bd6335fa6
1 changed files with 10 additions and 5 deletions
|
@ -294,26 +294,31 @@ Karl Marx - Die ursprüngliche Akkumulation
|
||||||
public function dataBBCodesToMarkdown()
|
public function dataBBCodesToMarkdown()
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
'bug-7808-gt' => [
|
'bug-7808-gt' => [
|
||||||
'expected' => '>`>`',
|
'expected' => '>`>`',
|
||||||
'text' => '>[code]>[/code]',
|
'text' => '>[code]>[/code]',
|
||||||
],
|
],
|
||||||
'bug-7808-lt' => [
|
'bug-7808-lt' => [
|
||||||
'expected' => '<`<`',
|
'expected' => '<`<`',
|
||||||
'text' => '<[code]<[/code]',
|
'text' => '<[code]<[/code]',
|
||||||
],
|
],
|
||||||
'bug-7808-amp' => [
|
'bug-7808-amp' => [
|
||||||
'expected' => '&`&`',
|
'expected' => '&`&`',
|
||||||
'text' => '&[code]&[/code]',
|
'text' => '&[code]&[/code]',
|
||||||
],
|
],
|
||||||
'bug-12701-quotes' => [
|
'bug-12701-quotes' => [
|
||||||
'expected' => '[](https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581)',
|
'expected' => '[](https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581)',
|
||||||
'text' => '[url=https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581][img=https://domain.tld/photo/86912721086415cdc8e0a03226831581-1.png]abc"fgh[/img][/url]'
|
'text' => '[url=https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581][img=https://domain.tld/photo/86912721086415cdc8e0a03226831581-1.png]abc"fgh[/img][/url]'
|
||||||
],
|
],
|
||||||
'bug-12701-no-quotes' => [
|
'bug-12701-no-quotes' => [
|
||||||
'expected' => '[](https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581)',
|
'expected' => '[](https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581)',
|
||||||
'text' => '[url=https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581][img=https://domain.tld/photo/86912721086415cdc8e0a03226831581-1.png]abcfgh[/img][/url]'
|
'text' => '[url=https://domain.tld/photos/user/image/86912721086415cdc8e0a03226831581][img=https://domain.tld/photo/86912721086415cdc8e0a03226831581-1.png]abcfgh[/img][/url]'
|
||||||
],
|
],
|
||||||
|
/** @see https://github.com/friendica/friendica/pull/14908 */
|
||||||
|
'task-14908-strip-tags' => [
|
||||||
|
'expected' => 'Norddeutscher Bürger !\[Noddeutscher Bürger - Bismark Brötchen (Roger Cziwerny - pixapay)\](/rscamo/……)',
|
||||||
|
'text' => '[class=postbox-ocean]Norddeutscher Bürger [/class]',
|
||||||
|
],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue