Improve login flow

After user logs in, until now they would be redirected to the edit profile page until their profile is complete. Now they will be redirected there only for the first time and then every 5th login until their profile is complete.
I think using randomness in tests is generally best avoided: they should be repeatable.