jasmine setup error rails 3.1 ActiveSupport :: Concern(NameError)

时间:2011-06-08 03:48:46

标签: ruby-on-rails-3 testing rspec-rails jasmine

我正在尝试按照其网站上的说明设置Jasmine Gem。跑完后:

bundle exec jasmine init

我收到错误:

/Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/railties-3.1.0.rc1/lib/rails/railtie/configurable.rb:4:in `<module:Configurable>': uninitialized constant ActiveSupport::Concern (NameError)
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/railties-3.1.0.rc1/lib/rails/railtie/configurable.rb:3:in `<class:Railtie>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/railties-3.1.0.rc1/lib/rails/railtie/configurable.rb:2:in `<module:Rails>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/railties-3.1.0.rc1/lib/rails/railtie/configurable.rb:1:in `<top (required)>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/railties-3.1.0.rc1/lib/rails/railtie.rb:129:in `inherited'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/lib/jasmine/railtie.rb:3:in `<module:Jasmine>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/lib/jasmine/railtie.rb:2:in `<top (required)>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/lib/jasmine.rb:12:in `require'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/lib/jasmine.rb:12:in `<top (required)>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/bin/jasmine:4:in `require'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/gems/jasmine-1.0.2.1/bin/jasmine:4:in `<top (required)>'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/bin/jasmine:19:in `load'
from /Users/sts-158imac/.rvm/gems/ruby-1.9.2-p180@fmn/bin/jasmine:19:in `<main>'

1 个答案:

答案 0 :(得分:5)

而不是尝试使用bundle exec jasmine init

设置Jamine

尝试使用rails g jasmine:install,在您的Gemfile中插入jasmine gem后,一旦捆绑安装就可以使用{{1}}。 `