Passed
Push — master ( 53af6f...4b20bd )
by Alexander
02:25 queued 10s
created

NotReadableStream::isReadable()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 1
b 0
f 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Yii\Web\Tests\Emitter\Support;
6
7
use Psr\Http\Message\StreamInterface;
8
9
class NotReadableStream implements StreamInterface
10
{
11
    public function __toString(): string
12
    {
13
        throw new \RuntimeException();
14
    }
15
    public function close(): void
16
    {
17
    }
18
    public function detach()
19
    {
20
        return null;
21
    }
22
    public function getSize(): ?int
23
    {
24
        return null;
25
    }
26
    public function tell(): int
27
    {
28
        throw new \RuntimeException();
29
    }
30
    public function eof(): bool
31
    {
32
        return false;
33
    }
34
    public function isSeekable(): bool
35
    {
36
        return false;
37
    }
38
    public function seek($offset, $whence = SEEK_SET): void
39
    {
40
        throw new \RuntimeException();
41
    }
42
    public function rewind(): void
43
    {
44
        throw new \RuntimeException();
45
    }
46
    public function isWritable(): bool
47
    {
48
        return false;
49
    }
50
    public function write($string): int
51
    {
52
        throw new \RuntimeException();
53
    }
54
    public function isReadable(): bool
55
    {
56
        return false;
57
    }
58
    public function read($length): string
59
    {
60
        throw new \RuntimeException();
61
    }
62
    public function getContents(): string
63
    {
64
        throw new \RuntimeException();
65
    }
66
    public function getMetadata($key = null)
67
    {
68
        return null;
69
    }
70
}
71