在窗口中运行RSPEC的错误:找不到WebPack binstubs



当我运行rspec时,我会收到以下错误:

C:UsersChloeworkspacecatalyst_research>rspec
Randomized with seed 41345
FFFFFFF............................FFFFFFFC:/ruby24/lib/ruby/gems/2.4.0/gems/webpacker-2.0/lib/tasks/installers.rake:1: warning: already initialized constant INSTALLERS
C:/ruby24/lib/ruby/gems/2.4.0/gems/webpacker-2.0/lib/tasks/installers.rake:1: warning: previous definition of INSTALLERS was here
C:/ruby24/lib/ruby/gems/2.4.0/gems/webpacker-2.0/lib/tasks/webpacker/install.rake:1: warning: already initialized constant WEBPACKER_APP_TEMPLATE_PATH
C:/ruby24/lib/ruby/gems/2.4.0/gems/webpacker-2.0/lib/tasks/webpacker/install.rake:1: warning: previous definition of WEBPACKER_APP_TEMPLATE_PATH was here
C:/Users/Chloe/workspace/catalyst_research/lib/tasks/test.rake:6: warning: already initialized constant DRIVERS
C:/Users/Chloe/workspace/catalyst_research/lib/tasks/test.rake:6: warning: previous definition of DRIVERS was here
Webpack binstubs not found.
Make sure the bin directory or binstubs are not included in .gitignore
Exiting!

我确实有 bin/webpack

C:UsersChloeworkspacecatalyst_research>ls bin/webpack
bin/webpack

我确实成功运行了npm install(一些警告(

C:UsersChloeworkspacecatalyst_research>npm install
npm WARN rollback Rolling back tar-pack@3.4.0 failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:UsersChloeworkspacecatalyst_researchnode_modulesfseventsnode_modules'
npm WARN ajv-keywords@3.1.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.3 (node_modulesfsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
up to date in 34.749s

rails test什么都没运行:

C:UsersChloeworkspacecatalyst_research>rails test
...
0 runs, 0 assertions, 0 failures, 0 errors, 0 skips

rake test在上面给出了相同的错误。grep webpack .gitignore一无所获。我对RSPEC并不熟悉。我已经5年没有使用过了。由于这些不兼容的问题,我更喜欢最大的。

  • Rails 5.0.6,
  • RSPEC 3.7,
  • 纱线1.5.1,
  • NPM 5.6.0,
  • 节点9.10.1,
  • Windows 8.1,
  • Ruby 2.4.3,
  • webpack〜> 2.0

我将/bin/webpack-dev-server重命名为 bin/webpack-dev-server.rb,因为它是一个红宝石文件,没有在工头中启动。当我重命名后,RSPEC重新开始工作。

最新更新