Skip to content

Commit

Permalink
test case
Browse files Browse the repository at this point in the history
  • Loading branch information
PawelSuwinski committed May 25, 2022
1 parent ef83533 commit 2c2d18d
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions tests/php/FileNameFilterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,11 @@ public function testFilterWithCustomRules()
);
}

public function testFilterWithEmptyString()
/**
* @dataProvider providerFilterWithEmptyString
*/
public function testFilterWithEmptyString($name)
{
$name = 'ö ö ö.jpg';
$filter = new FileNameFilter();
$filter->setTransliterator(new Transliterator());
$result = $filter->filter($name);
Expand All @@ -78,6 +80,14 @@ public function testFilterWithEmptyString()
);
}

public function providerFilterWithEmptyString()
{
return [
['ö ö ö.jpg'],
['新しいファイル.jpg'],
];
}

public function testUnderscoresStartOfNameRemoved()
{
$name = '_test.txt';
Expand Down

0 comments on commit 2c2d18d

Please sign in to comment.