public function shouldFailEntryAndExitWithNonCallable() { $state = new State('a'); $context = new Context(new Identifier('123', 'foo-machine')); $event = 'foo'; $callable = "Foo::BarEntry"; $state->setEntryCallable($callable); $callable = "Foo::BarExit"; $state->setExitCallable($callable); try { $state->entryAction($context); $this->fail('should not come here'); } catch (Exception $e) { $this->assertEquals(Exception::CALLABLE_FAILURE, $e->getCode()); } try { $state->exitAction($context); $this->fail('should not come here'); } catch (Exception $e) { $this->assertEquals(Exception::CALLABLE_FAILURE, $e->getCode()); } }