我正在关注使用 Rails 进行敏捷 Web 开发,第三版第 14 章。
我在windows中使用命令行输入这个命令: D:\InstantRails-2.0-win\rails_apps\GraduateDesign\depot>ruby -I test test/unit/product_test.rb
错误消息显示如下:
D:/InstantRails-2.0-win/rails_apps/GraduateDesign/depot/app/controllers/users_co
ntroller.rb:48: warning: don't put space before argument parentheses
D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/acti
ve_support/dependencies.rb:445:in `load_missing_constant': uninitialized constan
t RUBY_COPYRIGHT (NameError)
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/activesupport-2
.2.2/lib/active_support/dependencies.rb:77:in `const_missing'
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/activesupport-2
.2.2/lib/active_support/dependencies.rb:89:in `const_missing'
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/rbx-require-rel
ative-0.0.9/lib/require_relative.rb:51
from D:/InstantRails-2.0-win/ruby/lib/ruby/site_ruby/1.8/rubygems/custom
_require.rb:36:in `gem_original_require'
from D:/InstantRails-2.0-win/ruby/lib/ruby/site_ruby/1.8/rubygems/custom
_require.rb:36:in `require'
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/activesupport-2
.2.2/lib/active_support/dependencies.rb:155:in `require'
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/linecache-0.45-
x86-mswin32/lib/linecache.rb:66
from D:/InstantRails-2.0-win/ruby/lib/ruby/site_ruby/1.8/rubygems/custom
_require.rb:31:in `gem_original_require'
... 16 levels...
from D:/InstantRails-2.0-win/ruby/lib/ruby/gems/1.8/gems/activesupport-2
.2.2/lib/active_support/dependencies.rb:155:in `require'
from D:/InstantRails-2.0-win/rails_apps/GraduateDesign/depot/test/test_h
elper.rb:3
from test/unit/product_test.rb:1:in `require'
from test/unit/product_test.rb:1