PhpSpec\CodeAnalysis\AccessInspector::isPropertyWritable PHP Méthode

isPropertyWritable() public méthode

public isPropertyWritable ( object $object, string $property ) : boolean
$object object
$property string
Résultat boolean
    public function isPropertyWritable($object, $property);

Usage Example

Exemple #1
0
 function it_sets_a_property_on_the_wrapped_object(WrappedObject $wrappedObject, AccessInspector $accessInspector)
 {
     $obj = new \stdClass();
     $obj->id = 1;
     $accessInspector->isPropertyWritable(Argument::type('stdClass'), 'id')->willReturn('true');
     $wrappedObject->isInstantiated()->willReturn(true);
     $wrappedObject->getInstance()->willReturn($obj);
     $this->set('id', 2)->shouldReturn(2);
 }
All Usage Examples Of PhpSpec\CodeAnalysis\AccessInspector::isPropertyWritable