#6017 requesting clear('nonExistingEntityName')
should raise a MappingException
This commit is contained in:
parent
8f77afdc34
commit
c1038096e0
@ -4,6 +4,7 @@ namespace Doctrine\Tests\ORM;
|
||||
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
use Doctrine\Common\NotifyPropertyChanged;
|
||||
use Doctrine\Common\Persistence\Mapping\MappingException;
|
||||
use Doctrine\Common\PropertyChangedListener;
|
||||
use Doctrine\ORM\Mapping\ClassMetadata;
|
||||
use Doctrine\ORM\ORMInvalidArgumentException;
|
||||
@ -362,6 +363,16 @@ class UnitOfWorkTest extends OrmTestCase
|
||||
$this->_unitOfWork->clear($entity);
|
||||
}
|
||||
|
||||
/**
|
||||
* @group 6017
|
||||
*/
|
||||
public function testClearManagerWithUnknownEntityName()
|
||||
{
|
||||
$this->expectException(MappingException::class);
|
||||
|
||||
$this->_unitOfWork->clear(uniqid('nonExisting', true));
|
||||
}
|
||||
|
||||
/**
|
||||
* @group 6017
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user