diff --git a/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php b/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php index 523baf071..61957aa1e 100644 --- a/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php +++ b/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php @@ -355,11 +355,10 @@ class UnitOfWorkTest extends OrmTestCase */ public function testClearManagerWithObject() { - $this->expectException(ORMException::class); - $this->expectExceptionMessage('must be a string'); - $entity = new Country(456, 'United Kingdom'); + $this->expectException(ORMInvalidArgumentException::class); + $this->_unitOfWork->clear($entity); }