| Conditions | 2 |
| Paths | 2 |
| Total Lines | 25 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 26 | public function it_configures_using_configuration() |
||
| 27 | { |
||
| 28 | // @todo Test production config. |
||
| 29 | $app = $this->createApplication(); |
||
| 30 | |||
| 31 | $this->assertTrue($app->getName() === 'Test name'); |
||
| 32 | $this->assertTrue($app->getVersion() === 'Test version'); |
||
| 33 | |||
| 34 | $commands = [ |
||
| 35 | FakeDefaultCommand::class, |
||
| 36 | FakeExtraCommand::class, |
||
| 37 | ]; |
||
| 38 | |||
| 39 | $appCommands = collect($app->all()) |
||
| 40 | ->map( |
||
| 41 | function ($command) { |
||
| 42 | return get_class($command); |
||
| 43 | } |
||
| 44 | ) |
||
| 45 | ->toArray(); |
||
| 46 | |||
| 47 | foreach ($commands as $command) { |
||
| 48 | $this->assertTrue(in_array($command, $appCommands)); |
||
| 49 | } |
||
| 50 | } |
||
| 51 | |||
| 63 |