mirror of
https://github.com/Respect/Validation.git
synced 2026-03-17 07:45:45 +01:00
19 lines
No EOL
493 B
PHP
19 lines
No EOL
493 B
PHP
<?php
|
|
|
|
namespace Respect\Validation\Exceptions;
|
|
|
|
|
|
class AbstractGroupedExceptionTest extends \PHPUnit_Framework_TestCase
|
|
{
|
|
function test_one_or_more_grouped_exceptions_should_be_condensed_by_getRelated()
|
|
{
|
|
$int =new IntException();
|
|
$e = new AbstractGroupedException;
|
|
$e2 = new AbstractNestedException;
|
|
$e->addRelated($e2);
|
|
$e2->addRelated($int);
|
|
$result = $e->getRelated();
|
|
$this->assertSame($int, current($result));
|
|
}
|
|
|
|
} |