Module: PintrestApi::Authentication
- Included in:
- Pin
- Defined in:
- lib/pintrest_api/authentication.rb
Overview
Pintrest Boards this is used to fetch boards and related pins
Constant Summary collapse
- EMAIL_INPUT_CSS =
'.loginUsername input'- PASSWORD_INPUT_CSS =
'.loginPassword input'- LOGIN_PAGE_BUTTON_CSS =
'.formFooter .formFooterButtons'- PINTREST_LOGIN_URL =
'https://www.pinterest.com/login/'
Instance Method Summary collapse
Instance Method Details
#login(authentication) ⇒ Object
9 10 11 12 13 14 15 16 17 18 |
# File 'lib/pintrest_api/authentication.rb', line 9 def login(authentication) visit PINTREST_LOGIN_URL @session.find(EMAIL_INPUT_CSS).set authentication[:email] @session.find(PASSWORD_INPUT_CSS).set authentication[:password] click LOGIN_PAGE_BUTTON_CSS sleep 5 puts 'Finished logging in' end |