Exemplo n.º 1
0
 /**
  * Test fetch COOKIE params
  */
 public function testCookies()
 {
     $env = \Slim\Environment::mock(array('HTTP_COOKIE' => 'foo=bar; abc=123'));
     $req = new \Slim\Http\Request($env);
     $this->assertEquals(2, count($req->cookies()));
     $this->assertEquals('bar', $req->cookies('foo'));
     $this->assertNull($req->cookies('xyz'));
 }