Local   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A run() 0 11 1
A __toString() 0 4 1
1
<?php
2
3
namespace Assimtech\Tempo\Node;
4
5
use ArrayObject;
6
use Symfony\Component\Process\Process;
7
8
class Local extends ArrayObject implements NodeInterface
9
{
10
    /**
11
     * {@inheritdoc}
12
     */
13 1
    public function run($command)
14
    {
15 1
        $process = new Process($command);
16
17
        $process
18 1
            ->setTimeout(null)
19 1
            ->mustRun()
20
        ;
21
22 1
        return $process->getOutput();
23
    }
24
25
    /**
26
     * {@inheritdoc}
27
     */
28 1
    public function __toString()
29
    {
30 1
        return 'localhost';
31
    }
32
}
33