What Does Bundle Exec Rspec Do
This Command Executes the Command, Making All Gems Specified in the Gemfile(5) Available to Require in Ruby Programs. Essentially, If You Would Normally Have...
This command executes the command, making all gems specified in the Gemfile(5) available to require in Ruby programs. Essentially, if you would normally have run something like rspec spec/my_spec.
Why do I have to use bundle exec?
Using bundle exec guarantees that the program is run with the environment specified in the gemfile, which hopefully means it is the environment that the creators of the program want it to be run in, which hopefully means it should run correctly no matter what weird setup you have on your computer.
How do I run an rspec file?
File & Directory Names RSpec can take a file name or directory name and run the file or the contents of the directory. So you can do: rspec spec/jobs to run the tests found in the jobs directory. rspec spec/jobs spec/services to run only tests found in the jobs and services directory.