/**
  * Create a new HashedPassword
  *
  * @param Password $password
  * @return HashedPassword
  */
 public function hash(Password $password)
 {
     return new HashedPassword($this->hasher->make($password->toString()));
 }
Exemple #2
0
 /** @test */
 public function should_return_as_string()
 {
     $password = new Password('qwertyuiop');
     $this->assertEquals('qwertyuiop', $password->toString());
 }