You are here

public function LuhnValidatorTest::getInvalidNumbers in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/Tests/Constraints/LuhnValidatorTest.php \Symfony\Component\Validator\Tests\Constraints\LuhnValidatorTest::getInvalidNumbers()

File

vendor/symfony/validator/Tests/Constraints/LuhnValidatorTest.php, line 95

Class

LuhnValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function getInvalidNumbers() {
  return array(
    array(
      '1234567812345678',
      Luhn::CHECKSUM_FAILED_ERROR,
    ),
    array(
      '4222222222222222',
      Luhn::CHECKSUM_FAILED_ERROR,
    ),
    array(
      '0000000000000000',
      Luhn::CHECKSUM_FAILED_ERROR,
    ),
    array(
      '000000!000000000',
      Luhn::INVALID_CHARACTERS_ERROR,
    ),
    array(
      '42-22222222222222',
      Luhn::INVALID_CHARACTERS_ERROR,
    ),
  );
}