Ejemplo n.º 1
0
 public function testGetAttribute()
 {
     $attribute = $this->getMockBuilder('Oro\\Bundle\\WorkflowBundle\\Model\\Attribute')->disableOriginalConstructor()->getMock();
     $attribute->expects($this->any())->method('getName')->will($this->returnValue('test'));
     $attributes = new ArrayCollection(array('test' => $attribute));
     $attributeManager = new AttributeManager();
     $attributeManager->setAttributes($attributes);
     $this->assertSame($attribute, $attributeManager->getAttribute('test'));
 }