Code Duplication    Length = 11-12 lines in 3 locations

Tests/Transport/Subscriber/PublisherTest.php 3 locations

@@ 15-26 (lines=12) @@
12
13
class PublisherTest extends BaseTestCase
14
{
15
    public function testGetQueueName()
16
    {
17
        $publisher = new Publisher(
18
            'exch_test',
19
            ExchangeType::FANOUT,
20
            $this->getConnectionManagerMock(),
21
            'from_name_test',
22
            'test'
23
        );
24
25
        $this->assertEquals('test', $publisher->getQueueName());
26
    }
27
28
    public function testGetExchange()
29
    {
@@ 40-50 (lines=11) @@
37
        $this->assertEquals('exch_test', $publisher->getExchange());
38
    }
39
40
    public function testGetExchangeType()
41
    {
42
        $publisher = new Publisher(
43
            'exch_test',
44
            ExchangeType::DIRECT,
45
            $this->getConnectionManagerMock(),
46
            'test'
47
        );
48
49
        $this->assertEquals(ExchangeType::DIRECT, $publisher->getExchangeType());
50
    }
51
52
    public function testRefreshChannel()
53
    {
@@ 76-87 (lines=12) @@
73
        $this->assertInstanceOf(CmobiAMQPChannel::class, $publisher->refreshChannel());
74
    }
75
76
    public function testGetFromName()
77
    {
78
        $publisher = new Publisher(
79
            'exch_test',
80
            ExchangeType::FANOUT,
81
            $this->getConnectionManagerMock(),
82
            'caller_test',
83
            ''
84
        );
85
86
        $this->assertEquals('caller_test', $publisher->getFromName());
87
    }
88
89
    /**
90
     * @return ConnectionManager