Exemplo n.º 1
0
 /**
  * @test
  */
 public function multipleFeatures_AllEnabled()
 {
     $feature = new Feature('test');
     $feature->addSwitcher(Simple::on());
     $feature->addSwitcher(Simple::on());
     $this->assertTrue($feature->isEnabled());
 }
Exemplo n.º 2
0
 /**
  * @param string $key
  * @param bool $status
  * @return Feature
  */
 public static function buildFeature($key, $status)
 {
     $feature = new Feature($key);
     if ($status) {
         $feature->addSwitcher(Simple::on());
     }
     return $feature;
 }
Exemplo n.º 3
0
 /**
  * @test
  */
 public function staticHelperEnabled()
 {
     $switcher = new Simple();
     $switcher->enable();
     $this->assertEquals($switcher, Simple::on());
 }