Add unit test for session