cbeer / engine_cart

Rake tasks to generate test applications for Rails Engines
MIT License
18 stars 16 forks source link

APP_ROOT is not set #3

Closed jcoyne closed 11 years ago

jcoyne commented 11 years ago
uninitialized constant APP_ROOT
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/engine_cart-0.0.2/lib/engine_cart/tasks/engine_cart.rake:51:in `within_test_app'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/engine_cart-0.0.2/lib/engine_cart/tasks/engine_cart.rake:32:in `block (2 levels) in <top (required)>'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:236:in `call'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:236:in `block in execute'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:231:in `each'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:231:in `execute'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:175:in `block in invoke_with_call_chain'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/monitor.rb:211:in `mon_synchronize'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:168:in `invoke_with_call_chain'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/task.rb:161:in `invoke'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:149:in `invoke_task'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `block (2 levels) in top_level'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `each'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:106:in `block in top_level'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:115:in `run_with_threads'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:100:in `top_level'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:78:in `block in run'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:165:in `standard_exception_handling'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/lib/rake/application.rb:75:in `run'
/Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/rake-10.1.0/bin/rake:33:in `<top (required)>'
/Users/justin/.rbenv/versions/2.0.0-p247/bin/rake:23:in `load'
/Users/justin/.rbenv/versions/2.0.0-p247/bin/rake:23:in `<main>'
Tasks: TOP => engine_cart:generate
jcoyne commented 11 years ago

I'm able to fix this by adding this line to my Rakefile APP_ROOT= File.expand_path(File.dirname(__FILE__))

cbeer commented 11 years ago

I don't know why we need APP_ROOT in the first place.

cbeer commented 11 years ago

Removed in f93c8e1