Advertisement
Guest User

Untitled

a guest
Sep 15th, 2014
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. webdriver.get(url)
  2. webdriver.add_cookie({'name': 'sessionid', 'value': webdriver.session_id}) # Probably not necessary but just in case
  3.  
  4. session = Session(webdriver.session_id, SessionStore().encode({}), datetime.now()+timedelta(days=70))
  5. session.save()
  6.  
  7. webdriver.get(url)
  8. # expect this session to not need to login
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement