Enhance test coverage on views/activity.py