Added the FSM example and tests.