Example #1
0
 public function testSearchForAMissingElementReturnsFalse()
 {
     $collection = new Collection();
     $collection->add((object) array('property' => '12345'));
     $collection->add((object) array('property' => '12'));
     $collection->add((object) array('property' => '2'));
     $this->assertFalse($collection->exists(function ($element) {
         return $element->property === '1';
     }));
 }