| Total Complexity | 3 |
| Total Lines | 22 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 10 | class WriterTest extends TestCase |
||
| 11 | { |
||
| 12 | /** @test */ |
||
| 13 | public function it_respects_is_contract(): void |
||
| 14 | { |
||
| 15 | $this->assertInstanceOf(WriterContract::class, new Writer()); |
||
| 16 | } |
||
| 17 | |||
| 18 | /** @test */ |
||
| 19 | public function it_gets_the_output(): void |
||
| 20 | { |
||
| 21 | $writer = new Writer($output = new ConsoleOutput()); |
||
| 22 | |||
| 23 | $this->assertEquals($writer->getOutput(), $output); |
||
| 24 | } |
||
| 25 | |||
| 26 | /** @test */ |
||
| 27 | public function it_sets_the_output(): void |
||
| 28 | { |
||
| 29 | $writer = (new Writer())->setOutput($output = new ConsoleOutput()); |
||
| 30 | |||
| 31 | $this->assertEquals($writer->getOutput(), $output); |
||
| 32 | } |
||
| 34 |