basic state machine for applicants with tests
Merge branch 'state_machine_for_applicants' into dev