public function shouldLoadTransitionsFromFile()
{
$machine = new StateMachine(new Context(new Identifier('xml-test', 'test-machine')));
$this->assertCount(0, $machine->getTransitions());
//this is a symbolic link to the asset/xml/example.xml file
$loader = XML::createFromFile(__DIR__ . '/fixture-example.xml');
$count = $loader->load($machine);
$this->assertCount(4, $machine->getTransitions(), 'there is a regex transition that adds 2 transitions (a-c and b-c)');
$this->assertEquals(4, $count);
$this->assertEquals(0, MyStatic::$guard);
$this->assertTrue($machine->ab());
$this->assertEquals(1, MyStatic::$guard, 'guard callable specified in xml should be called');
$this->assertTrue($machine->bdone());
$this->assertEquals(2, MyStatic::$entry, '2 entry state callables in config');
$this->assertEquals(1, MyStatic::$exit, '1 exit state callable in config');
}