Completed
Push — master ( dd1955...c3a87b )
by Michael
10s
created

NotInteractiveTerminalTest   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
dl 0
loc 14
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A testOutputNotInteractive() 0 5 1
A testInputNotInteractive() 0 5 1
1
<?php
2
3
namespace PhpSchool\TerminalTest\Exception;
4
5
use PhpSchool\Terminal\Exception\NotInteractiveTerminal;
6
use PHPUnit\Framework\TestCase;
7
8
/**
9
 * @author Aydin Hassan <[email protected]>
10
 */
11
class NotInteractiveTerminalTest extends TestCase
12
{
13
    public function testInputNotInteractive() : void
14
    {
15
        $e = NotInteractiveTerminal::inputNotInteractive();
16
17
        self::assertEquals('Input stream is not interactive (non TTY)', $e->getMessage());
18
    }
19
20
    public function testOutputNotInteractive() : void
21
    {
22
        $e = NotInteractiveTerminal::outputNotInteractive();
23
24
        self::assertEquals('Output stream is not interactive (non TTY)', $e->getMessage());
25
    }
26
}
27