unit test for sessions