/** * Test offset unset method removes elements from collection * * @return void */ public function testOffsetUnset() { $this->assertTrue($this->collection->offsetExists(2)); $this->assertAttributeCount(5, 'elements', $this->collection); $this->collection->offsetUnset(2); $this->assertFalse($this->collection->offsetExists(2)); $this->assertAttributeCount(4, 'elements', $this->collection); }