add test cases for SessionsController
implement SessionsController