testing cookies with stubs

Please review!