Skip to content

Commit

Permalink
Add tests for Finder exclude root absolute
Browse files Browse the repository at this point in the history
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
  • Loading branch information
joshtrichards committed May 8, 2024
1 parent ca2ca8b commit 70e0ac4
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ public static function getAcceptData()
'foo/bar.tmp',
'test.php',
'toto',
'toto/foo',
'toto/.git',
'foo bar',
'qux',
Expand Down Expand Up @@ -96,12 +97,36 @@ public static function getAcceptData()
'qux_10_2.php',
'qux_12_0.php',
'qux_2_0.php',
];

$foo_absolute_root = [
'.bar',
'.foo',
'.foo/.bar',
'.foo/bar',
'.git',
'test.py',
'test.php',
'toto',
'toto/foo',
'toto/.git',
'foo bar',
'qux',
'qux/baz_100_1.py',
'qux/baz_1_2.py',
'qux_0_1.php',
'qux_1000_1.php',
'qux_1002_0.php',
'qux_10_2.php',
'qux_12_0.php',
'qux_2_0.php',
];

return [
[['foo'], self::toAbsolute($foo)],
[['fo'], self::toAbsolute($fo)],
[['toto/'], self::toAbsolute($toto)],
[['/foo'], self::toAbsolute($foo_absolute_root)],
];
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ public static function setUpBeforeClass(): void
'foo/bar.tmp',
'test.php',
'toto/',
'toto/foo/',
'toto/.git/',
'foo bar',
'qux_0_1.php',
Expand Down

0 comments on commit 70e0ac4

Please sign in to comment.