-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit 975ea0a
committed
Add selenium to avoid loading issue in 'action_dispatch/system_test_case'
On Rails 6 we add error in test suite like:
```
LoadError: cannot load such file -- selenium/webdriver System test integration requires Rails >= 5.1 and has a hard dependency on a webserver and `capybara`, please add capybara to your Gemfile and configure a webserver (e.g. `Capybara.server = :webrick`) before attempting to use system specs.
```
Thoses errors come from
`lib/rspec/rails/example/system_example_group.rb#L51`:
```
2.6.3 :002 > require 'action_dispatch/system_test_case'
Traceback (most recent call last):
16: from /Users/bti/code/rspec-dev/repos/rspec-rails/spec/rspec/rails/example/system_example_group_spec.rb:11:in `block (4 levels) in <module:Rails>'
15: from /Users/bti/code/rspec-dev/repos/rspec-rails/spec/rspec/rails/example/system_example_group_spec.rb:11:in `include'
14: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/concern.rb:122:in `append_features'
13: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/concern.rb:122:in `class_eval'
12: from /Users/bti/code/rspec-dev/repos/rspec-rails/lib/rspec/rails/example/system_example_group.rb:50:in `block in <module:SystemExampleGroup>'
11: from <internal:prelude>:145:in `irb'
10: from (irb):2:in `block in <module:SystemExampleGroup>'
9: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
8: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:291:in `load_dependency'
7: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `block in require'
6: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
5: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/actionpack-6.0.0/lib/action_dispatch/system_test_case.rb:7:in `<top (required)>'
4: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
3: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:291:in `load_dependency'
2: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `block in require'
1: from /Users/bti/.rvm/gems/ruby-2.6.3/gems/activesupport-6.0.0/lib/active_support/dependencies.rb:325:in `require'
LoadError (cannot load such file -- selenium/webdriver)
```
This is probably related to:
> rails/rails#36592
We need to load selenium-driver if we are in Rails 61 parent 0129555 commit 975ea0aCopy full SHA for 975ea0a
Expand file treeCollapse file tree
1 file changed
+1
-0
lines changed+1Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
32 | 32 |
| |
33 | 33 |
| |
34 | 34 |
| |
| 35 | + | |
35 | 36 |
| |
36 | 37 |
| |
37 | 38 |
| |
|
0 commit comments