You are here

public function ConstraintViolationListTest::testAdd in Plug 7

File

lib/Symfony/validator/Symfony/Component/Validator/Tests/ConstraintViolationListTest.php, line 45

Class

ConstraintViolationListTest

Namespace

Symfony\Component\Validator\Tests

Code

public function testAdd() {
  $violation = $this
    ->getViolation('Error');
  $this->list
    ->add($violation);
  $this
    ->assertCount(1, $this->list);
  $this
    ->assertSame($violation, $this->list[0]);
}