1 | <?php |
||
13 | class ConfigurationTest extends TestCase |
||
14 | { |
||
15 | use ConfigurationTestCaseTrait; |
||
16 | |||
17 | /** |
||
18 | * @return \Symfony\Component\Config\Definition\ConfigurationInterface |
||
19 | */ |
||
20 | protected function getConfiguration() |
||
24 | |||
25 | public function testConfigGeneratesAsExpected() |
||
33 | |||
34 | public function testConfigDoesntGenerateAsExpected() |
||
38 | |||
39 | /** |
||
40 | * @expectedException \InvalidArgumentException |
||
41 | * @expectedExceptionMessage Entity "App\UndefinedEntity" does not exist |
||
42 | */ |
||
43 | public function testConfigUndefinedEntity() |
||
53 | |||
54 | /** |
||
55 | * @expectedException \RuntimeException |
||
56 | * @expectedExceptionMessage The entity class "Kunstmaan\ConfigBundle\Tests\DependencyInjection\InvalidConfigEntity" needs to implement the Kunstmaan\ConfigBundle\Entity\ConfigurationInterface |
||
57 | */ |
||
58 | public function testConfigInvalidEntity() |
||
68 | |||
69 | public function testConfigValidEntity() |
||
79 | } |
||
80 | |||
107 |
Having each class in a dedicated file usually plays nice with PSR autoloaders and is therefore a well established practice. If you use other autoloaders, you might not want to follow this rule.