-foreach (http\Client::getAvailableDrivers() as $driver) {
- $client = new http\Client($driver);
- foreach($client->enqueue($request)->send()->getResponse()->getCookies(0, array("comment")) as $cookies) {
- var_dump($cookies->toArray());
+server("cookie2.inc", function($port) {
+ $request = new http\Client\Request("GET", "http://localhost:$port");
+
+ foreach (http\Client::getAvailableDrivers() as $driver) {
+ $client = new http\Client($driver);
+ foreach($client->enqueue($request)->send()->getResponse()->getCookies(0, array("comment")) as $cookies) {
+ var_dump($cookies->toArray());
+ }