예제 #1
0
파일: Token.php 프로젝트: spriebsch/phpca
 /**
  * Returns the name of the constant representing this token as a string.
  *
  * @return string
  */
 public function getName()
 {
     return Constants::getTokenName($this->id);
 }
예제 #2
0
 /**
  * @covers spriebsch\PHPca\Constants::getTokenName
  * @expectedException \RuntimeException
  */
 public function testGetTokenNameThrowsExceptionOnUnknownToken()
 {
     Constants::init();
     Constants::getTokenName(9999);
 }