public function testPropertiesMethods() { $properties = array($prop1 = new Property('prop1'), $prop2 = new Property('prop2'), $prop3 = new Property('prop3')); $this->class->setProperties($properties); $this->assertEquals($properties, $this->class->getProperties(), 'Set And Get Properties test'); $this->class->addProperty($prop4 = new Property('prop4')); $this->assertEquals(array($prop1, $prop2, $prop3, $prop4), $this->class->getProperties(), 'AddProperty method test'); $this->class->removeProperty('prop2'); $this->assertEquals(array($prop1, $prop3, $prop4), \array_values($this->class->getProperties()), 'Remove property test'); $this->assertEquals($this->class->getProperty('prop1'), $prop1, 'GetProperty Test'); $this->setExpectedException('InvalidArgumentException'); $this->class->getProperty('prop2'); }