Conditions | 1 |
Paths | 1 |
Total Lines | 17 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
21 | protected function setUp() |
||
22 | { |
||
23 | $this->extension = new NetteAdapterForSymfonyBundlesExtension(); |
||
24 | $compiler = new Compiler(new ContainerBuilder()); |
||
25 | $this->extension->setCompiler($compiler, 'symfonyBundles'); |
||
26 | |||
27 | // simulates required Nette\Configurator default parameters |
||
28 | $compiler->addConfig([ |
||
29 | 'parameters' => [ |
||
30 | 'appDir' => '', |
||
31 | 'tempDir' => ContainerFactory::createAndReturnTempDir(), |
||
32 | 'debugMode' => true, |
||
33 | 'productionMode' => true, |
||
34 | 'environment' => '', |
||
35 | ], |
||
36 | ]); |
||
37 | } |
||
38 | |||
50 |
If a method or function can return multiple different values and unless you are sure that you only can receive a single value in this context, we recommend to add an additional type check:
If this a common case that PHP Analyzer should handle natively, please let us know by opening an issue.