Пример #1
0
 function let(HashGenerator $hashGenerator)
 {
     $hashGenerator->generate(a::any(), a::any())->willReturn($this->hash);
     $this->beConstructedWith($hashGenerator);
 }
Пример #2
0
 /**
  * @param string $hashAlgorithm
  * @return string
  */
 protected function generateHash($hashAlgorithm)
 {
     $base = $this->getHashBase();
     return $this->hashGenerator->generate($hashAlgorithm, $base);
 }