Пример #1
0
 /**
  * @param $name
  * @return Feature|null
  */
 public function findByName($name)
 {
     return $this->repository->findByName($name);
 }
Пример #2
0
 function it_throws_exception_when_given_context_is_not_found(Repository $repository, Strategy $strategy)
 {
     $feature = new Feature('captcha', $strategy->getWrappedObject());
     $repository->findByName('captcha')->willReturn($feature);
     $this->shouldThrow(new ContextNotFoundException("Context with name 'fffuuuu' was not found."))->during('isActive', array('captcha', 'fffuuuu'));
 }