Ejemplo n.º 1
0
 /**
  * @covers \examples\statemachines\Door\Door::close
  * @covers \examples\statemachines\Door\AbstractDoorState::close
  * @expectedException \examples\statemachines\Door\IllegalStateTransitionException
  */
 public function testCannotClose()
 {
     $this->door->close();
 }
Ejemplo n.º 2
0
 /**
  * @covers \examples\statemachines\Door\Door::close
  * @covers \examples\statemachines\Door\OpenDoorState::close
  * @uses   \examples\statemachines\Door\Door::isClosedDoorState
  */
 public function testCanClose()
 {
     $this->door->close();
     $this->assertTrue($this->door->isClosedDoorState());
 }