/** * Tests get- and setHeaders. */ public function testGetSetHeaders() { $request = new Request(); $request->setHeaders(array('key' => 'value')); $this->assertCount(1, $request->getHeaders()); $this->assertEquals('value', $request->getHeader('key')); }
/** * Tests createWithHeaders method. */ public function testCreateWithHeaders() { $request = Request::createWithHeaders(array('header')); $this->assertContains('header', $request->getHeaders()); }