Completed
Push — develop ( c86111...2faf16 )
by ANTHONIUS
21s
created

TestCase   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 33
Duplicated Lines 0 %

Test Coverage

Coverage 53.33%

Importance

Changes 0
Metric Value
eloc 12
dl 0
loc 33
rs 10
c 0
b 0
f 0
ccs 8
cts 15
cp 0.5333
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getResult() 0 3 1
A setResult() 0 3 1
A getName() 0 3 1
A __construct() 0 3 1
1
<?php
2
3
/*
4
 * This file is part of the doyo/behat-coverage-extension project.
5
 *
6
 * (c) Anthonius Munthi <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Doyo\Behat\Coverage\Bridge\CodeCoverage;
15
16
class TestCase
17
{
18
    const RESULT_UNKNOWN = -1;
19
    const RESULT_PASSED  = 0;
20
    const RESULT_SKIPPED = 1;
21
    const RESULT_ERROR   = 5;
22
    const RESULT_FAILED  = 3;
23
24
    private $name;
25
26
    private $result;
27
28 4
    public function __construct($name)
29
    {
30 4
        $this->name = $name;
31
    }
32
33 6
    public function setResult($result)
34
    {
35 6
        $this->result = $result;
36
    }
37
38 1
    public function getResult()
39
    {
40 1
        return $this->result;
41
    }
42
43
    /**
44
     * @return string
45
     */
46 2
    public function getName()
47
    {
48 2
        return $this->name;
49
    }
50
}
51