Пример #1
0
 /**
  * @test
  *
  * @depends createHashMustReturnAHashAccordingWithTheAlgorithm
  *
  * @uses \Lcobucci\JWT\Signer\Hmac::createHash
  * @uses \Lcobucci\JWT\Signer\Key
  *
  * @covers \Lcobucci\JWT\Signer\Hmac::doVerify
  */
 public function doVerifyShouldReturnFalseWhenExpectedHashWasNotCreatedWithSameInformation($expected)
 {
     self::assertFalse($this->signer->doVerify($expected, 'test', new Key('1234')));
 }
Пример #2
0
 /**
  * @test
  *
  * @uses Lcobucci\JWT\Signer\Key
  *
  * @covers Lcobucci\JWT\Signer\Hmac::doVerify
  */
 public function doVerifyShouldReturnFalseWhenExpectedHashIsNotString()
 {
     $this->assertFalse($this->signer->doVerify(false, 'test', new Key('1234')));
 }