bundle安装后,Factory_bot_rails无法安装

发布于 2025-01-18 09:58:59 字数 275 浏览 2 评论 0原文

尝试安装factory_bot_rails gem,但是执行捆绑>捆绑安装

There was an error parsing `Gemfile`: Undefined local variable or method `‘factory_bot_rails’' for Gemfile. Bundler cannot continue.

我的rvm是最新的...问题到底是什么?

提前致谢。

Trying to install the factory_bot_rails gem, but running into this after executing bundle install:

There was an error parsing `Gemfile`: Undefined local variable or method `‘factory_bot_rails’' for Gemfile. Bundler cannot continue.

My rvm is up to date...what exactly is the problem?

Thanks in advance.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

左耳近心 2025-01-25 09:58:59

我认为问题是宝石的写作方式。

只需在项目的根目录中键入控制台:

gem install factory_bot_rails

或将GEM文件放入您的GEM文件

group :development, :test do
  gem 'factory_bot_rails'
end

之后:

bundle install

源: htttps:/// github.com/thoughtbot/factory_bot_rails

I think the problem is how the gem is wrote.

Just type on a console in the project's root directory:

gem install factory_bot_rails

or put inside your Gem file

group :development, :test do
  gem 'factory_bot_rails'
end

After type:

bundle install

source: https://github.com/thoughtbot/factory_bot_rails enter link description here

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文