As per observations by Steve Bates fixed tests using the state variable and refactored state to initial_state in the FiniteStateMachine implementation.