You are here

public function FinderTest::testContains in Database Sanitize 7

@dataProvider getContainsTestData

File

vendor/symfony/finder/Tests/FinderTest.php, line 483

Class

FinderTest

Namespace

Symfony\Component\Finder\Tests

Code

public function testContains($matchPatterns, $noMatchPatterns, $expected) {
  $finder = $this
    ->buildFinder();
  $finder
    ->in(__DIR__ . \DIRECTORY_SEPARATOR . 'Fixtures')
    ->name('*.txt')
    ->sortByName()
    ->contains($matchPatterns)
    ->notContains($noMatchPatterns);
  $this
    ->assertIterator($this
    ->toAbsoluteFixtures($expected), $finder);
}