You are here

public function IpValidatorTest::testInvalidReservedIpsV4 in Plug 7

@dataProvider getInvalidReservedIpsV4

File

lib/Symfony/validator/Symfony/Component/Validator/Tests/Constraints/IpValidatorTest.php, line 203

Class

IpValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

public function testInvalidReservedIpsV4($ip) {
  $constraint = new Ip(array(
    'version' => Ip::V4_NO_RES,
    'message' => 'myMessage',
  ));
  $this->validator
    ->validate($ip, $constraint);
  $this
    ->buildViolation('myMessage')
    ->setParameter('{{ value }}', '"' . $ip . '"')
    ->assertRaised();
}