You are here

public function IssnValidatorTest::testInvalidIssn in Plug 7

@dataProvider getInvalidIssn

File

lib/Symfony/validator/Symfony/Component/Validator/Tests/Constraints/IssnValidatorTest.php, line 174

Class

IssnValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function testInvalidIssn($issn, $code) {
  $constraint = new Issn(array(
    'message' => 'myMessage',
  ));
  $this->validator
    ->validate($issn, $constraint);
  $this
    ->buildViolation('myMessage')
    ->setParameter('{{ value }}', '"' . $issn . '"')
    ->setCode($code)
    ->assertRaised();
}