Sha256: f19235a4f5dba4a49a0ffc33261a86fbf79e8668fed10b22acae71e023ad144b
Contents?: true
Size: 867 Bytes
Versions: 6
Compression:
Stored size: 867 Bytes
Contents
class ViewCase < ActionView::TestCase include Capybara::DSL include Capybara::Assertions include Rails.application.routes.url_helpers def teardown Capybara.reset_session! Capybara.current_driver = :poltergeist end private def login(password = 'foobar') fill_in 'inputEmail', with: adminpanel_users(:valid).email fill_in 'inputPassword', with: password #pass is foobar click_button I18n.t('authentication.new-session') end def login_user_with_rol(rol) fill_in 'inputEmail', with: adminpanel_users(rol).email fill_in 'inputPassword', with: 'foobar' #pass is foobar click_button I18n.t('authentication.new-session') end def submit_modal(button) click_button button #the modal submit is a button actually, not a link sleep 0.5 end def trigger_modal(link) click_link link sleep 0.5 end end
Version data entries
6 entries across 6 versions & 1 rubygems