Unable to run "system" tests in Rails 5.2 when using WSL (Windows Subsystem for Linux)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Unable to run "system" tests in Rails 5.2 when using WSL (Windows Subsystem for Linux)

David McDonald
I'm currently using WSL on Windows 10 for developing in Rails.  So far I've never had any issues, but noticed I'm unable to run "system" tests.  

For testing I've done the following:

  • "rails new sample" (created a new rails 5.2 app called sample)
  • "rails generate scaffold user first_name:string last_name:string" (created resource for running system tests)
  • rails test test/system/users_test.rb (this command produced the following)

daveomcd@LAPTOP-GDA9LTDQ:~/rails_projects/sample$ rails test test/system/users_test.rb
Running via Spring preloader in process 2613
/home/daveomcd/.rvm/gems/ruby-2.4.2/gems/spring-2.0.2/lib/spring/application.rb:185: warning: Insecure world writable dir /home/daveomcd/.rvm/gems/ruby-2.4.2/bin in PATH, mode 040777
Run options: --seed 35177


# Running:


E


Error:
UsersTest#test_destroying_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
 
(unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)
    test/system/users_test.rb:38:in `block in <class:UsersTest>'



Error:
UsersTest#test_destroying_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
 
(unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)






bin/rails test test/system/users_test.rb:37


E


Error:
UsersTest#test_creating_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
  (unknown error: DevToolsActivePort file doesn'
t exist)
 
(The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
 
(Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)
    test
/system/users_test.rb:14:in `block in <class:UsersTest>'


Error:
UsersTest#test_creating_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
  (unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)






bin/rails test test/system/users_test.rb:13


E


Error:
UsersTest#test_updating_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
  (unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)
    test/system/users_test.rb:26:in `
block in <class:UsersTest>'


Error:
UsersTest#test_updating_a_User:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
  (unknown error: DevToolsActivePort file doesn'
t exist)
 
(The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
 
(Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)






bin
/rails test test/system/users_test.rb:25


E


Error:
UsersTest#test_visiting_the_index:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
 
(unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)
    test/system/users_test.rb:9:in `block in <class:UsersTest>'



Error:
UsersTest#test_visiting_the_index:
Selenium::WebDriver::Error::UnknownError: unknown error: Chrome failed to start: exited abnormally
 
(unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=2.42.591071 (0b695ff80972cc1a65a5cd643186d2ae582cd4ac),platform=Linux 4.4.0-17134-Microsoft x86_64)






bin/rails test test/system/users_test.rb:8






Finished in 22.996091s, 0.1739 runs/s, 0.0000 assertions/s.
4 runs, 0 assertions, 0 failures, 4 errors, 0 skips

Can anyone tell me if this is a WSL issue? Or if I'm doing anything wrong?  I'm struggling on options to debug, troubleshoot this issue.  Thanks!

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/47cfba36-d745-42c6-b586-61f6ccea9593%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.