Added switch-with and a state machine example as test