Skip to content

Commit 243704e

Browse files
committed
Add custom headers for test client
1 parent 308fd6d commit 243704e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/There4/Slim/Test/WebTestClient.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ private function request($method, $path, $data = array(), $optionalHeaders = arr
8686
$env = Slim\Environment::getInstance();
8787
$this->app->router = new NoCacheRouter($this->app->router);
8888
$this->app->request = new Slim\Http\Request($env);
89+
// Custom headers
90+
$this->app->request->headers = new Slim\Http\Headers($env);
8991
$this->app->response = new Slim\Http\Response();
9092

9193
// Establish some useful references to the slim app properties

0 commit comments

Comments
 (0)