public function IsbnValidatorTest::testInvalidIsbn

@dataProvider getInvalidIsbn

File

drupal/core/vendor/symfony/validator/Symfony/Component/Validator/Tests/Constraints/IsbnValidatorTest.php, line 213

Class

IsbnValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function testInvalidIsbn($isbn) {
  $constraint = new Isbn(array(
    'isbn10' => true,
    'isbn13' => true,
  ));
  $this->context
    ->expects($this
    ->once())
    ->method('addViolation')
    ->with($constraint->bothIsbnMessage);
  $this->validator
    ->validate($isbn, $constraint);
}