session, User: avoid ambiguity in login flow
The `session` module should be about lower level, not object-oriented, primitives that don't care about caching of web drivers and generally maintaining state. The `login_as_user()` method did not fit there, because it called to the Heptapod object, which does exactly that. This was an ambiguity, that could easily lead to infinite loops when developping new features. It is a better fit on the `User` class. Actually the next natural move would be to make `webdriver` a property, renaming the current attribute to `_webdriver` as already done with `python_gitlab_client`. The only caller, in `test_projects`, is updated by this.
Showing with 8 additions and 10 deletions