gpt4 book ai didi

ruby-on-rails - rails - 找不到生成器 rspec :install.

转载 作者:数据小太阳 更新时间:2023-10-29 07:25:08 26 4
gpt4 key购买 nike

我不知道它找不到生成器。

gem install rspec
Fetching: rspec-core-2.8.0.gem (100%)
Fetching: rspec-expectations-2.8.0.gem (100%)
Fetching: rspec-mocks-2.8.0.gem (100%)
Fetching: rspec-2.8.0.gem (100%)
Successfully installed rspec-core-2.8.0
Successfully installed rspec-expectations-2.8.0
Successfully installed rspec-mocks-2.8.0
Successfully installed rspec-2.8.0
4 gems installed
Installing ri documentation for rspec-core-2.8.0...
Installing ri documentation for rspec-expectations-2.8.0...
Installing ri documentation for rspec-mocks-2.8.0...
Installing ri documentation for rspec-2.8.0...
Installing RDoc documentation for rspec-core-2.8.0...
Installing RDoc documentation for rspec-expectations-2.8.0...
Installing RDoc documentation for rspec-mocks-2.8.0...
Installing RDoc documentation for rspec-2.8.0...

$bundle install
...
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed.
$ script/rails generate rspec:install
Could not find generator rspec:install.

最佳答案

我会将以下内容添加到您的 Gemfile,我认为您缺少 rspec-rails gem。

  group :development, :test do
gem "rspec-rails"
end

关于ruby-on-rails - rails - 找不到生成器 rspec :install.,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9004758/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com