Skip to content

Commit

Permalink
Ability to yield files with names (#2732)
Browse files Browse the repository at this point in the history
  • Loading branch information
Wirone committed Aug 4, 2022
1 parent a494d7c commit 685dc70
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/Testing/PHPUnit/AbstractRectorTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,14 @@ protected function yieldFilesFromDirectory(string $directory, string $suffix = '
return StaticFixtureFinder::yieldDirectoryExclusively($directory, $suffix);
}

/**
* @return Iterator<string, array<int, SmartFileInfo>>
*/
protected function yieldFilesWithPathnameFromDirectory(string $directory, string $suffix = '*.php.inc'): Iterator
{
return StaticFixtureFinder::yieldDirectoryExclusivelyWithRelativePathname($directory, $suffix);
}

protected function isWindows(): bool
{
return strncasecmp(PHP_OS, 'WIN', 3) === 0;
Expand Down

0 comments on commit 685dc70

Please sign in to comment.