TestResultWithAbnormalTermination::setTestOutput()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Paraunit\TestResult;
6
7
/**
8
 * Class TestResultWithAbnormalTermination
9
 * @package Paraunit\TestResult
10
 */
11
class TestResultWithAbnormalTermination extends TestResultWithMessage
12
{
13
    /** @var string */
14
    private $testOutput;
15
16 9
    public function getFailureMessage(): string
17
    {
18 9
        return parent::getFailureMessage() . "\n" . $this->testOutput;
19
    }
20
21
    public function getTestOutput(): string
22
    {
23
        return $this->testOutput;
24
    }
25
26 15
    public function setTestOutput(string $testOutput)
27
    {
28 15
        $this->testOutput = $testOutput;
29
    }
30
}
31