Esempio n. 1
0
 function it_is_not_active_when_non_of_strategies_arent_active(Strategy $strategy1, Strategy $strategy2, Feature $feature, Context $context)
 {
     $this->beConstructedWith(array($strategy1, $strategy2));
     $strategy1->isActive($feature, $context)->willReturn(false);
     $strategy2->isActive($feature, $context)->willReturn(false);
     $this->isActive($feature, $context)->shouldReturn(false);
 }
Esempio n. 2
0
 /**
  * @param  Context $context
  * @return bool
  */
 public function isActive(Context $context)
 {
     return $this->strategy->isActive($this, $context);
 }