You are here

public function IdenticalToValidatorTest::provideInvalidComparisons in Zircon Profile 8

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

Return value

array

Overrides AbstractComparisonValidatorTestCase::provideInvalidComparisons

File

vendor/symfony/validator/Tests/Constraints/IdenticalToValidatorTest.php, line 78

Class

IdenticalToValidatorTest
@author Daniel Holmes <daniel@danielholmes.org>

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function provideInvalidComparisons() {
  return array(
    array(
      1,
      '1',
      2,
      '2',
      'integer',
    ),
    array(
      2,
      '2',
      '2',
      '"2"',
      'string',
    ),
    array(
      '22',
      '"22"',
      '333',
      '"333"',
      'string',
    ),
    array(
      new \DateTime('2001-01-01'),
      'Jan 1, 2001, 12:00 AM',
      new \DateTime('2001-01-01'),
      'Jan 1, 2001, 12:00 AM',
      'DateTime',
    ),
    array(
      new \DateTime('2001-01-01'),
      'Jan 1, 2001, 12:00 AM',
      new \DateTime('1999-01-01'),
      'Jan 1, 1999, 12:00 AM',
      'DateTime',
    ),
    array(
      new ComparisonTest_Class(4),
      '4',
      new ComparisonTest_Class(5),
      '5',
      __NAMESPACE__ . '\\ComparisonTest_Class',
    ),
  );
}