getEncoder() public method

See also: Symfony\Component\Security\Core\Encoder\EncoderFactory::getEncoder()
public getEncoder ( Symfony\Component\Security\Core\User\AccountInterface $account )
$account Symfony\Component\Security\Core\User\AccountInterface
 public function testGetEncoderWithGenericAccount()
 {
     $genericFactory = $this->getMock('Symfony\\Component\\Security\\Core\\Encoder\\EncoderFactoryInterface');
     $encoder = $this->getMock('Symfony\\Component\\Security\\Core\\Encoder\\PasswordEncoderInterface');
     $genericFactory->expects($this->once())->method('getEncoder')->will($this->returnValue($encoder));
     $factory = new EncoderFactory(null, false, 1, $genericFactory);
     $this->assertSame($encoder, $factory->getEncoder($this->getMock('Symfony\\Component\\Security\\Core\\User\\AccountInterface')));
 }