| @@ 35-42 (lines=8) @@ | ||
| 32 | $this->verifier = new ExpirationVerifier(); | |
| 33 | } | |
| 34 | ||
| 35 | public function testMissingExpiry() | |
| 36 |     { | |
| 37 | $this->payload->expects($this->once()) | |
| 38 |                       ->method('findClaimByName') | |
| 39 | ->will($this->returnValue(null)); | |
| 40 | ||
| 41 | $this->verifier->verify($this->token); | |
| 42 | } | |
| 43 | ||
| 44 | /** | |
| 45 | * @expectedException \Emarref\Jwt\Exception\ExpiredException | |
| @@ 37-45 (lines=9) @@ | ||
| 34 | $this->verifier = new NotBeforeVerifier(); | |
| 35 | } | |
| 36 | ||
| 37 | public function testMissingNotBefore() | |
| 38 |     { | |
| 39 | $this->payload->expects($this->once()) | |
| 40 |                       ->method('findClaimByName') | |
| 41 | ->with(NotBefore::NAME) | |
| 42 | ->will($this->returnValue(null)); | |
| 43 | ||
| 44 | $this->verifier->verify($this->token); | |
| 45 | } | |
| 46 | ||
| 47 | /** | |
| 48 | * @expectedException \Emarref\Jwt\Exception\TooEarlyException | |