diff options
author | Mario <mario@mariovavti.com> | 2024-05-03 12:04:19 +0200 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2024-05-03 12:04:19 +0200 |
commit | 219f0dfeca0cccc1870ca9da608d5004d43e67fb (patch) | |
tree | bd0b58c822f323d74c446add788aa1e6b4483890 /tests/unit | |
parent | 3a50a0b71572d0f5cc5c5aed1df8592c3e9e4dce (diff) | |
download | volse-hubzilla-219f0dfeca0cccc1870ca9da608d5004d43e67fb.tar.gz volse-hubzilla-219f0dfeca0cccc1870ca9da608d5004d43e67fb.tar.bz2 volse-hubzilla-219f0dfeca0cccc1870ca9da608d5004d43e67fb.zip |
also deal with ol and ul tags earlier and add test for double nested lists
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/includes/BBCodeTest.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/unit/includes/BBCodeTest.php b/tests/unit/includes/BBCodeTest.php index 2697c5069..34e127a30 100644 --- a/tests/unit/includes/BBCodeTest.php +++ b/tests/unit/includes/BBCodeTest.php @@ -239,6 +239,10 @@ class BBCodeTest extends UnitTestCase { '<ul><li>list 1</li><li>list 2</li><li>list 3</li><ul><li>list 1</li><li>list 2</li><li>list 3</li></ul></ul>', '[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[/list][/list]' ], + 'double nested list' => [ + '<ul><li>list 1</li><li>list 2</li><li>list 3</li><ul><li>list 1</li><li>list 2</li><li>list 3</li><ul><li>list 1</li><li>list 2</li><li>list 3</li></ul></ul></ul>', + '[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[/list][/list][/list]' + ], 'list without closing li' => [ '<ul><li>list 1<li>list 2<li>list 3</ul>', '[list][*]list 1[*]list 2[*]list 3[/list]' @@ -246,6 +250,10 @@ class BBCodeTest extends UnitTestCase { 'nested list without closing li' => [ '<ul><li>list 1<li>list 2<li>list 3<ul><li>list 1<li>list 2<li>list 3</ul></ul>', '[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[/list][/list]' + ], + 'double nested list without closing li' => [ + '<ul><li>list 1<li>list 2<li>list 3<ul><li>list 1<li>list 2<li>list 3<ul><li>list 1<li>list 2<li>list 3</ul></ul></ul>', + '[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[list][*]list 1[*]list 2[*]list 3[/list][/list][/list]' ] ]; } |