fix errors and failures

Fix errors from test/functional/automated_tests_controller_test.rb, add strong parameters of assignment model and update helper file.

Update some test cases according to the new rails API
Line is too long. [144/80]