RSpec > Is there a way to run all tests with one command?

后端 未结 5 1373
萌比男神i
萌比男神i 2021-02-02 07:44

Is there a command that does this? I\'ve searched but can not find anything

5条回答
  •  -上瘾入骨i
    2021-02-02 08:42

    For controller test

    1. bundle exec rake spec:controllers

    For model test

    1. bundle exec rake spec:models

    For all test

    1. bundle exec rake spec

    For specific file test do

    1. rspec file_name_spec.rb (example rspec spec/controllers/groups_controller_spec.rb)

提交回复
热议问题