Code Duplication    Length = 7-8 lines in 2 locations

tests/ResponseTest.php 1 location

@@ 53-59 (lines=7) @@
50
        $this->assertSame('Created', $r2->getReasonPhrase());
51
    }
52
53
    public function testCanConstructWithHeaders()
54
    {
55
        $r = new Response(200, ['Foo' => 'Bar']);
56
        $this->assertSame(['Foo' => ['Bar']], $r->getHeaders());
57
        $this->assertSame('Bar', $r->getHeaderLine('Foo'));
58
        $this->assertSame(['Bar'], $r->getHeader('Foo'));
59
    }
60
61
    public function testCanConstructWithHeadersAsArray()
62
    {

tests/RequestTest.php 1 location

@@ 196-203 (lines=8) @@
193
        $this->assertEquals('zoobar, foobar, zoobar', $r->getHeaderLine('zoo'));
194
    }
195
196
    public function testSupportNumericHeaders()
197
    {
198
        $r = new Request('GET', '', [
199
            'Content-Length' => 200,
200
        ]);
201
        $this->assertSame(['Content-Length' => ['200']], $r->getHeaders());
202
        $this->assertSame('200', $r->getHeaderLine('Content-Length'));
203
    }
204
205
    public function testAddsPortToHeader()
206
    {