improved test coverage for user controller