diff --git a/tests/Doctrine/Tests/ORM/Functional/HydrationCacheTest.php b/tests/Doctrine/Tests/ORM/Functional/HydrationCacheTest.php index 821c5dff4..9dc556d4b 100644 --- a/tests/Doctrine/Tests/ORM/Functional/HydrationCacheTest.php +++ b/tests/Doctrine/Tests/ORM/Functional/HydrationCacheTest.php @@ -70,12 +70,10 @@ class HydrationCacheTest extends OrmFunctionalTestCase public function testHydrationParametersSerialization() { $cache = new ArrayCache(); - $user = new CmsUser(); - $user->id = 1; $dql = "SELECT u FROM Doctrine\Tests\Models\Cms\CmsUser u WHERE u.id = ?1"; $query = $this->_em->createQuery($dql) - ->setParameter(1, $user) + ->setParameter(1, $userId = 1) ->setHydrationCacheProfile(new QueryCacheProfile(null, null, $cache)); $query->getResult(); @@ -83,7 +81,7 @@ class HydrationCacheTest extends OrmFunctionalTestCase $c = $this->getCurrentQueryCount(); $query->getResult(); - + $this->assertEquals($c, $this->getCurrentQueryCount(), "Should not execute query. Its cached!"); } }