Пример #1
0
 /**
  * @param string|object|null $object
  * @return bool
  */
 public function supportsClass($object)
 {
     if (is_string($object)) {
         return parent::supportsClass($object);
     }
     return parent::supportsClass(get_class($object));
 }
Пример #2
0
 /**
  * @dataProvider getData
  */
 public function testVote($expectedVote, $object, $attributes, $message)
 {
     $this->assertEquals($expectedVote, $this->voter->vote($this->token, $object, $attributes), $message);
 }