Total Complexity | 3 |
Total Lines | 23 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
11 | class RequestBuilderSpec extends ObjectBehavior |
||
12 | { |
||
13 | public function let( |
||
14 | RequestFactory $requestFactory |
||
15 | ) { |
||
16 | $this->beConstructedWith( |
||
17 | $requestFactory |
||
18 | ); |
||
19 | } |
||
20 | |||
21 | public function it_is_initializable() |
||
22 | { |
||
23 | $this->shouldHaveType(RequestBuilder::class); |
||
24 | } |
||
25 | |||
26 | public function it_should_create_request($requestFactory) |
||
27 | { |
||
28 | $requestFactory |
||
29 | ->createRequest('GET', '/api', [], null) |
||
30 | ->shouldBeCalled() |
||
31 | ->willReturn(m::mock(RequestInterface::class)); |
||
32 | |||
33 | $this->create('GET', '/api')->shouldReturnAnInstanceOf(RequestInterface::class); |
||
34 | } |
||
36 |