Handling devise session destory and mocha deprecation