diff options
Diffstat (limited to 'test/application_system_test_case.rb')
-rw-r--r-- | test/application_system_test_case.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/test/application_system_test_case.rb b/test/application_system_test_case.rb index 4a6fd0d30..38d69e7c8 100644 --- a/test/application_system_test_case.rb +++ b/test/application_system_test_case.rb @@ -43,6 +43,11 @@ class ApplicationSystemTestCase < ActionDispatch::SystemTestCase driver_option.add_preference 'download.default_directory', DOWNLOADS_PATH.gsub(File::SEPARATOR, File::ALT_SEPARATOR || File::SEPARATOR) driver_option.add_preference 'download.prompt_for_download', false driver_option.add_preference 'plugins.plugins_disabled', ["Chrome PDF Viewer"] + # Disable "Change your password" popup shown after login due to leak detection + driver_option.add_preference 'profile.password_manager_leak_detection', false + # Disable password saving prompts + driver_option.add_preference 'profile.password_manager_enabled', false + driver_option.add_preference 'credentials_enable_service', false end setup do @@ -68,13 +73,13 @@ class ApplicationSystemTestCase < ActionDispatch::SystemTestCase # using default browser locale which depend on system locale for "real" browsers drivers def log_user(login, password) visit '/my/page' - assert_equal '/login', current_path + assert_current_path '/login', :ignore_query => true within('#login-form form') do fill_in 'username', :with => login fill_in 'password', :with => password find('input[name=login]').click end - assert_equal '/my/page', current_path + assert_current_path '/my/page', :ignore_query => true end def wait_for_ajax |