| Conditions | 1 |
| Paths | 1 |
| Total Lines | 15 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php namespace Nimo\Tests; |
||
| 12 | public function testMiddleware() |
||
| 13 | { |
||
| 14 | $answerRes = $this->getResponseMock(); |
||
| 15 | $req = $this->getRequestMock(); |
||
| 16 | |||
| 17 | $middleware = $this->getMockForAbstractClass(AbstractMiddleware::class); |
||
| 18 | $middleware->expects(self::any()) |
||
| 19 | ->method('main') |
||
| 20 | ->willReturn($answerRes); |
||
| 21 | |||
| 22 | /** @noinspection PhpParamsInspection */ |
||
| 23 | $returnValue = $middleware->process($req, $this->throwHandler()); |
||
| 24 | |||
| 25 | $this->assertSame($answerRes, $returnValue); |
||
| 26 | } |
||
| 27 | |||
| 29 |