示例#1
0
 /**
  * @dataProvider flagProvider
  */
 public function testFlag(FlagInterface $flag, $default_state)
 {
     $this->assertEquals($default_state, $flag->isRaised());
     $flag->lower();
     $this->assertFalse($flag->isRaised());
     $flag->raise();
     $this->assertTrue($flag->isRaised());
     $flag->lower();
     $this->assertFalse($flag->isRaised());
 }
示例#2
0
 /**
  * Abort the next iteration of polling
  */
 public function abort()
 {
     $this->abort_flag->raise();
 }