cleaned up Statemachine files
- removed old examples
- fixed test cases