Added verifications to mode switching
Merge branch 'controllerTest' of http://github.com/ktn/Iter2 into controllerTest