From 9a393ccba72b6b45e1911e12cb352807eddb4e12 Mon Sep 17 00:00:00 2001 From: Marco Pivetta Date: Mon, 6 Jun 2016 01:48:32 +0200 Subject: [PATCH] Removed reliance on `::class` meta-constant (only available in PHP 5.5+) --- tests/Doctrine/Tests/Models/GeoNames/Country.php | 2 ++ tests/Doctrine/Tests/ORM/UnitOfWorkTest.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/Doctrine/Tests/Models/GeoNames/Country.php b/tests/Doctrine/Tests/Models/GeoNames/Country.php index ebde305f8..8af430a93 100644 --- a/tests/Doctrine/Tests/Models/GeoNames/Country.php +++ b/tests/Doctrine/Tests/Models/GeoNames/Country.php @@ -9,6 +9,8 @@ namespace Doctrine\Tests\Models\GeoNames; */ class Country { + const CLASSNAME = __CLASS__; + /** * @Id * @Column(type="string", length=2) diff --git a/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php b/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php index 2e0233ba2..9623cfbf4 100644 --- a/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php +++ b/tests/Doctrine/Tests/ORM/UnitOfWorkTest.php @@ -339,7 +339,7 @@ class UnitOfWorkTest extends \Doctrine\Tests\OrmTestCase $this->_unitOfWork->persist($entity2); $this->assertTrue($this->_unitOfWork->isInIdentityMap($entity2)); - $this->_unitOfWork->clear(Country::class); + $this->_unitOfWork->clear(Country::CLASSNAME); $this->assertTrue($this->_unitOfWork->isInIdentityMap($entity1)); $this->assertFalse($this->_unitOfWork->isInIdentityMap($entity2)); $this->assertTrue($this->_unitOfWork->isScheduledForInsert($entity1));