Completed
Push — master ( 9a7b87...ad20a3 )
by Alessandro
03:07
created

TextToConsole   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 21
ccs 0
cts 9
cp 0
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A process() 0 4 1
1
<?php
2
declare(strict_types=1);
3
4
namespace Paraunit\Coverage\Processor;
5
6
use Paraunit\Proxy\Coverage\CodeCoverage;
7
use Symfony\Component\Console\Output\OutputInterface;
8
9
/**
10
 * Class TextToConsole
11
 * @package Paraunit\Proxy\Coverage
12
 */
13
class TextToConsole extends AbstractText
14
{
15
    /** @var  OutputInterface */
16
    private $output;
17
18
    /**
19
     * TextToConsole constructor.
20
     * @param OutputInterface $output
21
     * @param bool $showColors
22
     */
23
    public function __construct(OutputInterface $output, bool $showColors)
24
    {
25
        parent::__construct($showColors);
26
        $this->output = $output;
27
    }
28
29
    public function process(CodeCoverage $codeCoverage)
30
    {
31
        $this->output->writeln($this->getTextCoverage($codeCoverage));
32
    }
33
}
34