rantly icon indicating copy to clipboard operation
rantly copied to clipboard

Using rantly with rspec-rails

Open diasbruno opened this issue 3 years ago • 3 comments

Hi,

I'm not sure if there is a problem with my project's setup (rails app), but when I try to use this package I got an error like cannot find -- rspec.

It seems that rspec-rails is its own project (use the base package like rspec-core, rspec-expectations and so on...).

By changing the rspec package to the rspec-rails everything works (see diasbruno/rantly#17111a38e8e98c97230ecf32454f0d666918ef77)

So, I don't know if this package should also provide an extension for this case: rspec_rails_extensions.rb.

diasbruno avatar May 28 '22 01:05 diasbruno

You can work around this by explicitly including rspec in your Gemfile, along with rspec-rails.

gem 'rspec'
gem 'rspec-rails'

bbugh avatar Jul 28 '22 21:07 bbugh

Thanks, @bbugh. I'll give it a try.

diasbruno avatar Jul 28 '22 21:07 diasbruno

I'm not sure if It would be a good idea since rspec e rspec-rails, they both use the same rspec "core" libraries, but they are 2 "different" projects...so, it should not be necessary to include rspec as a dependency - I think...

Maybe rantly could provide a specific extension for rspec-rails as rspec_rails_extensions.rb, so we don't need to add extra dependencies.

diasbruno avatar Jul 28 '22 21:07 diasbruno