1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-19 08:01:27 +02:00

[ticket/17387] Add test for when words are separated by a non-space character

PHPBB-17387
This commit is contained in:
Ruben Calvo
2024-09-02 13:52:46 +02:00
parent 66b6a5e1f3
commit 472b36877c
2 changed files with 8 additions and 2 deletions

View File

@@ -112,6 +112,12 @@ class phpbb_functions_content_get_context_test extends TestCase
'words' => ['word1', 'word2'],
'length' => 10,
'expected' => 'word1 ... word2',
],
'fruits_spanish' => [
'text' => 'Manzana,plátano,naranja,fresa,mango,uva,piña,pera,kiwi,cereza,sandía,melón,papaya,arándano,durazno',
'words' => ['piña'],
'length' => 20,
'expected' => '... uva,piña,pera, ...',
]
];
}