Sha512Test.php 860 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /**
  3. * This file is part of Lcobucci\JWT, a simple library to handle JWT and JWS
  4. *
  5. * @license http://opensource.org/licenses/BSD-3-Clause BSD-3-Clause
  6. */
  7. namespace Lcobucci\JWT\Signer\Hmac;
  8. /**
  9. * @author Luís Otávio Cobucci Oblonczyk <lcobucci@gmail.com>
  10. * @since 0.1.0
  11. */
  12. class Sha512Test extends \PHPUnit_Framework_TestCase
  13. {
  14. /**
  15. * @test
  16. *
  17. * @covers Lcobucci\JWT\Signer\Hmac\Sha512::getAlgorithmId
  18. */
  19. public function getAlgorithmIdMustBeCorrect()
  20. {
  21. $signer = new Sha512();
  22. $this->assertEquals('HS512', $signer->getAlgorithmId());
  23. }
  24. /**
  25. * @test
  26. *
  27. * @covers Lcobucci\JWT\Signer\Hmac\Sha512::getAlgorithm
  28. */
  29. public function getAlgorithmMustBeCorrect()
  30. {
  31. $signer = new Sha512();
  32. $this->assertEquals('sha512', $signer->getAlgorithm());
  33. }
  34. }