Just so you know …

Your are not authenticated, you have a restricted access. Feel free to login to get a better user experience.
Free for open source projects. Sign up here

Review of file features/step_definitions/cucumber_rails_steps.rb
on branch master

db9c056a2a | the | 151 fixed issues | 37 to go.   |   View branch on GitHub    |   Badge urls

This is a review of an integration branch. Instead of showing the difference between the given branch and the integration, we're showing here below all problems we found in the current codebase, so the list may be long.

This is a public review of a branch. It means that you can read it, even if you never contributed code to it. Be aware that we may hide some sensitive information regarding security issues.

16  def install_cucumber_rails(*options)
17    if options.include?(:not_in_test_group)
18      gem 'cucumber-rails', path: "#{File.expand_path('.')}"
19    else
20      gem 'cucumber-rails' , group: :test, require: false, path: "#{File.expand_path('.')}"
21    end
22    # From Rails 5.1 some gems are already part of the Gemfile
23    if Gem.loaded_specs['rails'].version < Gem::Version.new('5.1.0')
24      gem 'capybara', group: :test
25      gem 'selenium-webdriver', group: :test
26    else
27      # Make sure to restrict the selected selenium-webdriver version
28      # Since version 3 geckodriver is required to be installed
29      gemfile_text = File.read(expand_path('Gemfile'))
30      gemfile_text.gsub!("gem 'selenium-webdriver'", "gem 'selenium-webdriver', '~> 2.0'")
31      overwrite_file('Gemfile', gemfile_text)
32    end
33    gem 'rspec-rails', group: :test
34    gem 'database_cleaner', group: :test unless options.include?(:no_database_cleaner)
35    gem 'factory_girl', group: :test unless options.include?(:no_factory_girl)
36    # Newer versions of rake remove a method used by RSpec older versions
37    # See https://stackoverflow.com/questions/35893584/nomethoderror-undefined-method-last-comment-after-upgrading-to-rake-11#35893625
38    if Gem::Version.new(RSpec::Support::Version::STRING) < Gem::Version.new('3.4.4')