scope FSM and tests