Hi, thanks for your post! It was very useful. However I'm struggling a bit to get the system tests running.
I don't know if I'm missing something, but I'm getting a lot of errors when initializing Chromedriver.
Did you include it in your docker image? Is there any script you're executing on the build phase to install chromedriver and it's dependencies?
Thanks again for a great post
Felipe
Thank you for your comment, I updated the blog post.
Hey Felipe,
I think the error that you are getting is when the system test is trying to connect to the chrome driver in the separated container and failed.
I think this can help you by updating this file application_system_test_case.rb
application_system_test_case.rb
require "test_helper" require "socket" def prepare_options driver_options = { desired_capabilities: { chromeOptions: { args: %w[headless disable-gpu disable-dev-shm-usage] } } } driver_options[:url] = ENV['selenium_remote_url'] if ENV['selenium_remote_url'] driver_options end class ApplicationSystemTestCase < ActionDispatch::SystemTestCase driven_by :selenium, using: :chrome, screen_size: [1400, 1400], options: prepare_options end
Take attention to the code that fetch the selenium_remote_url from the env variable
selenium_remote_url
Thanks! That did the trick.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi, thanks for your post! It was very useful. However I'm struggling a bit to get the system tests running.
I don't know if I'm missing something, but I'm getting a lot of errors when initializing Chromedriver.
Did you include it in your docker image? Is there any script you're executing on the build phase to install chromedriver and it's dependencies?
Thanks again for a great post
Felipe
Thank you for your comment, I updated the blog post.
Hey Felipe,
I think the error that you are getting is when the system test is trying to connect to the chrome driver in the separated container and failed.
I think this can help you by updating this file
application_system_test_case.rb
Take attention to the code that fetch the
selenium_remote_url
from the env variableThanks! That did the trick.