| Conditions | 1 |
| Paths | 1 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | public function testLogin(): void |
||
| 13 | { |
||
| 14 | $response = $this->runApp('POST', '/login', ['email' => '[email protected]', 'password' => 'AnyPass1000']); |
||
| 15 | |||
| 16 | $result = (string) $response->getBody(); |
||
| 17 | |||
| 18 | self::$jwt = json_decode($result)->message->Authorization; |
||
| 19 | |||
| 20 | $this->assertEquals(200, $response->getStatusCode()); |
||
| 21 | $this->assertEquals('application/json', $response->getHeaderLine('Content-Type')); |
||
| 22 | $this->assertStringContainsString('Authorization', $result); |
||
| 23 | $this->assertStringContainsString('Bearer', $result); |
||
| 24 | } |
||
| 26 |