2

每当我在 Rails 3 应用程序(还没有自定义测试)上运行自动测试时,它就会挂起,loading autotest/rails_rspec2而且我对 Rails 仍然非常陌生,知道要检查/寻找什么。如果存在已知的兼容性问题,我已经包含了我的 gemfile。如果您还需要什么,请告诉我,谢谢!

编辑 我在 Ubuntu 10.10 上运行以防万一。

$ autotest
loading autotest/rails_rspec2

宝石文件

source 'http://rubygems.org'

gem 'rails'

# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'

gem 'mysql2'
gem 'sqlite3'
gem 'sqlite3-ruby', :require => 'sqlite3'
gem "haml"
gem "formtastic"
gem "will_paginate"
gem "devise"
gem "omniauth"
gem "cancan"
gem "delayed_job"
gem "whenever"
gem "memcache-client"
gem "capistrano"
gem "mail"
gem "haml-rails"
gem "compass"
gem "jquery-rails"
gem "rack-mount"

group :development, :test do
  gem "rspec"
  gem "rspec-rails", ">= 2.5.0"
  gem "autotest-standalone"
  gem "autotest-rails"
end

group :testing do
  gem "mocha"
  gem "shoulda"
  gem "factory_girl_rails"
end

group :development do
  gem "cheat"
  gem "bullet"
  gem "ruby-growl"

end

宝石版本

aaronh-chronic (0.3.9)
abstract (1.0.0)
actionmailer (3.0.5)
actionpack (3.0.5)
activemodel (3.0.5)
activerecord (3.0.5)
activeresource (3.0.5)
activesupport (3.0.5)
addressable (2.2.4)
arel (2.0.9)
autotest (4.4.6)
autotest-notification (2.3.1)
autotest-rails (4.1.0)
autotest-standalone (4.5.5)
bcrypt-ruby (2.1.4)
builder (2.1.2)
bullet (2.0.1)
bundler (1.0.11)
cancan (1.6.4, 1.6.3)
capistrano (2.5.20)
cheat (1.3.0)
compass (0.10.6)
daemons (1.1.0)
delayed_job (2.1.4)
devise (1.2.1)
diff-lcs (1.1.2)
erubis (2.6.6)
factory_girl (1.3.3)
factory_girl_rails (1.0.1)
faraday (0.5.7)
formtastic (1.2.3)
haml (3.0.25)
haml-rails (0.3.4)
highline (1.6.1)
i18n (0.5.0)
jquery-rails (0.2.7)
mail (2.2.15)
memcache-client (1.8.5)
meta_where (1.0.4)
mime-types (1.16)
mocha (0.9.12)
multi_json (0.0.5)
multipart-post (1.1.0)
mysql2 (0.2.7)
net-ldap (0.1.1)
net-scp (1.0.4)
net-sftp (2.0.5)
net-ssh (2.1.3)
net-ssh-gateway (1.0.1)
nokogiri (1.4.4)
oa-basic (0.2.0)
oa-core (0.2.0)
oa-enterprise (0.2.0)
oa-more (0.2.0)
oa-oauth (0.2.0)
oa-openid (0.2.0)
oauth (0.4.4)
oauth2 (0.1.1)
omniauth (0.2.0)
orm_adapter (0.0.4)
paperclip (2.3.8)
polyglot (0.3.1)
pyu-ruby-sasl (0.0.3.2)
rack (1.2.2)
rack-mount (0.6.14)
rack-openid (1.2.0)
rack-test (0.5.7)
rails (3.0.5)
railties (3.0.5)
rake (0.8.7)
rest-client (1.6.1)
rspec (2.5.0)
rspec-core (2.5.1)
rspec-expectations (2.5.0)
rspec-mocks (2.5.0)
rspec-rails (2.5.0)
ruby-growl (3.0)
ruby-openid (2.1.8)
ruby-openid-apps-discovery (1.2.0)
rubyntlm (0.1.1)
shoulda (2.11.3)
sqlite3 (1.3.3)
sqlite3-ruby (1.3.3)
thor (0.14.6)
treetop (1.4.9)
tzinfo (0.3.26, 0.3.25)
uniform_notifier (1.0.1)
warden (1.0.3)
whenever (0.6.7)
will_paginate (2.3.15)
ZenTest (4.5.0)
4

2 回答 2

2

它可能没有挂起,而是找不到任何要测试的东西。这可能是由于这篇关于 Rspec 更改的帖子。

有关长期解决方案,请参阅该博客文章。简单的快速修复是:

autotest -s rspec2

于 2011-04-14T20:31:14.990 回答
1

这个答案很旧,但我遇到了这个问题,所以对于任何有这个问题的人。我没有安装 gem “rspec-autotest”,你可以通过在项目的 Gemfile 中添加它来修复它

gem 'rspec-autotest'

或者只是输入

gem install rspec-autotest

你可以在这里找到项目

于 2015-09-04T20:44:18.070 回答