无法在ruby上运行rspec

rhfm7lfc  于 2022-12-03  发布在  Ruby
关注(0)|答案(1)|浏览(173)

你知道如何修复这个问题吗?我试着在Ruby上运行rspec,但是它是这样显示的。

LoadError:
  cannot load such file -- rspec/expectations
# ./spec/spec_helper.rb:20:in `block in <top (required)>'
# ./spec/spec_helper.rb:16:in `<top (required)>'
No examples found.
No examples found.

Finished in 0.01334 seconds (files took 1.46 seconds to load)
0 examples, 0 failures, 1 error occurred outside of examples

Finished in 0.01334 seconds (files took 1.46 seconds to load)
0 examples, 0 failures, 1 error occurred outside of examples
d5vmydt9

d5vmydt91#

我遇到了一个类似的问题(cucumber),我安装了两个不同版本的rspec-expectationsgem,新的版本引起了冲突。我检查了我的Gemlist,发现我有所需的版本和一个新的版本,所以我简单地卸载了新的版本,我就可以运行我的cucumber测试了。此外,还有很多解决方案引用here

相关问题