Add test cases for responder helper functions.
Move view helper function and create test case.