Merge "Improve "selfmove" message's wording"
[lhc/web/wiklou.git] / tests / phpunit / mocks / MockWebRequest.php
1 <?php
2
3 /**
4 * A mock WebRequest.
5 *
6 * If the code under test accesses the response via the request (see
7 * WebRequest#response), then you might be able to use this mock to simplify
8 * your tests.
9 */
10 class MockWebRequest extends WebRequest {
11 /**
12 * @var WebResponse
13 */
14 protected $response;
15
16 public function __construct( WebResponse $response ) {
17 parent::__construct();
18
19 $this->response = $response;
20 }
21
22 public function response() {
23 return $this->response;
24 }
25 }