From 031e79e726bf08f1fd3acb9047c63419e0377d62 Mon Sep 17 00:00:00 2001
From: Marco Pivetta <ocramius@gmail.com>
Date: Fri, 11 Aug 2017 15:14:42 +0200
Subject: [PATCH] #6613 #6614 correcting broken test that isn't using objects
 against a `PersistentCollection`

---
 tests/Doctrine/Tests/ORM/PersistentCollectionTest.php | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/tests/Doctrine/Tests/ORM/PersistentCollectionTest.php b/tests/Doctrine/Tests/ORM/PersistentCollectionTest.php
index 0e1c20f51..a678b7f50 100644
--- a/tests/Doctrine/Tests/ORM/PersistentCollectionTest.php
+++ b/tests/Doctrine/Tests/ORM/PersistentCollectionTest.php
@@ -115,10 +115,12 @@ class PersistentCollectionTest extends OrmTestCase
     {
         $this->setUpPersistentCollection();
 
-        $this->collection->add('dummy');
+        $dummy = new \stdClass();
+
+        $this->collection->add($dummy);
         $this->assertEquals([0], array_keys($this->collection->toArray()));
 
-        $this->collection->removeElement('dummy');
+        $this->collection->removeElement($dummy);
         $this->assertEquals([], array_keys($this->collection->toArray()));
     }
 
@@ -129,7 +131,7 @@ class PersistentCollectionTest extends OrmTestCase
     {
         $this->setUpPersistentCollection();
 
-        $this->collection->add('dummy');
+        $this->collection->add(new \stdClass());
         $this->collection->clear();
         $this->assertEquals([], array_keys($this->collection->toArray()));
     }