Refactor code and adjust test cases
Format code
Merge branch 'master' into Issue1880
[1880] Clean up InstructorCourseInstructorDeleteAction

fixes #1880