MockFileFinderTest.php

Same filename in other branches
  1. 8.9.x core/tests/Drupal/Tests/Component/Annotation/MockFileFinderTest.php
  2. 10 core/tests/Drupal/Tests/Component/Annotation/MockFileFinderTest.php
  3. 11.x core/tests/Drupal/Tests/Component/Annotation/MockFileFinderTest.php

Namespace

Drupal\Tests\Component\Annotation

File

core/tests/Drupal/Tests/Component/Annotation/MockFileFinderTest.php

View source
<?php

namespace Drupal\Tests\Component\Annotation;

use Drupal\Component\Annotation\Reflection\MockFileFinder;
use PHPUnit\Framework\TestCase;

/**
 * @coversDefaultClass \Drupal\Component\Annotation\Reflection\MockFileFinder
 * @group Annotation
 */
class MockFileFinderTest extends TestCase {
    
    /**
     * @covers ::create
     * @covers ::findFile
     */
    public function testFindFile() {
        $tmp = MockFileFinder::create('testfilename.txt');
        $this->assertEquals('testfilename.txt', $tmp->findFile('n/a'));
        $this->assertEquals('testfilename.txt', $tmp->findFile('SomeClass'));
    }

}

Classes

Title Deprecated Summary
MockFileFinderTest @coversDefaultClass \Drupal\Component\Annotation\Reflection\MockFileFinder @group Annotation

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.