-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #301 from gacela-project/test-DocBlockServiceNotFo…
…undException Add tests for DocBlockServiceNotFoundException
- Loading branch information
Showing
4 changed files
with
47 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
...it/Framework/ClassResolver/DependencyProvider/DependencyProviderNotFoundExceptionTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace GacelaTest\Unit\Framework\ClassResolver\DependencyProvider; | ||
|
||
use Gacela\Framework\ClassResolver\DependencyProvider\DependencyProviderNotFoundException; | ||
use PHPUnit\Framework\TestCase; | ||
|
||
final class DependencyProviderNotFoundExceptionTest extends TestCase | ||
{ | ||
public function test_exception_message(): void | ||
{ | ||
$exception = new DependencyProviderNotFoundException($this); | ||
|
||
$expected = <<<EOT | ||
ClassResolver Exception | ||
Cannot resolve the `DependencyProvider` for your module `DependencyProvider` | ||
You can fix this by adding the missing `DependencyProvider` to your module. | ||
E.g. `\GacelaTest\Unit\Framework\ClassResolver\DependencyProvider` | ||
EOT; | ||
|
||
self::assertSame($expected, $exception->getMessage()); | ||
} | ||
} |