Pulls/logout login

In Behat test, if the previous one scenario failed, it will not logout, blocked the following scenario. So add logout if still logged in for a new scenario.