You are here

public function IsFalseValidatorTest::testTrueIsInvalid in Zircon Profile 8

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

File

vendor/symfony/validator/Tests/Constraints/IsFalseValidatorTest.php, line 44

Class

IsFalseValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function testTrueIsInvalid() {
  $constraint = new IsFalse(array(
    'message' => 'myMessage',
  ));
  $this->validator
    ->validate(true, $constraint);
  $this
    ->buildViolation('myMessage')
    ->setParameter('{{ value }}', 'true')
    ->assertRaised();
}