Passed
Push — master ( d7fd0c...0cd2cd )
by Sam
04:33
created

MockSocket::resume()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 0

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 0
nc 1
nop 0
dl 0
loc 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
/*
4
 * This file is part of PHP DNS Server.
5
 *
6
 * (c) Yif Swery <[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
namespace yswery\DNS\Tests;
13
14
use Evenement\EventEmitterTrait;
15
use React\Datagram\SocketInterface;
16
17
class MockSocket implements SocketInterface
18
{
19
    use EventEmitterTrait;
20
21
    private $transmissions = [];
22
23
    public function send($data, $remoteAddress = null)
24
    {
25
        $this->transmissions[] = $data;
26
    }
27
28
    public function getLastTransmission(): string
29
    {
30
        return end($this->transmissions);
31
    }
32
33
    public function close()
34
    {
35
        // TODO: Implement close() method.
36
    }
37
38
    public function end()
39
    {
40
        // TODO: Implement end() method.
41
    }
42
43
    public function resume()
44
    {
45
        // TODO: Implement resume() method.
46
    }
47
48
    public function pause()
49
    {
50
        // TODO: Implement pause() method.
51
    }
52
53
    public function getLocalAddress()
54
    {
55
        // TODO: Implement getLocalAddress() method.
56
    }
57
58
    public function getRemoteAddress()
59
    {
60
        // TODO: Implement getRemoteAddress() method.
61
    }
62
}
63