diff --git a/src/DocBlock/ExampleFinder.php b/src/DocBlock/ExampleFinder.php index 3cc5dab3..ea79f7cb 100644 --- a/src/DocBlock/ExampleFinder.php +++ b/src/DocBlock/ExampleFinder.php @@ -10,7 +10,7 @@ * @link http://phpdoc.org */ -namespace phpDocumentor\Reflection; +namespace phpDocumentor\Reflection\DocBlock; use phpDocumentor\Reflection\DocBlock\Tags\Example; diff --git a/tests/unit/DocBlock/ExampleFinderTest.php b/tests/unit/DocBlock/ExampleFinderTest.php new file mode 100644 index 00000000..6e083d48 --- /dev/null +++ b/tests/unit/DocBlock/ExampleFinderTest.php @@ -0,0 +1,32 @@ + + */ +class ExampleFinderTest extends \PHPUnit_Framework_TestCase +{ + /** @var ExampleFinder */ + private $fixture; + + public function setUp() + { + $this->fixture = new ExampleFinder(); + } + + /** + * @covers ::find + * @covers ::getSourceDirectory + * @uses \phpDocumentor\Reflection\DocBlock\Tags\Example + * @uses \phpDocumentor\Reflection\DocBlock\Description + */ + public function testFileNotFound() + { + $example = new Example('./example.php', false, 1, 0, new Description('Test')); + $this->assertSame('** File not found : ./example.php **', $this->fixture->find($example)); + } +}