rurounijones / yarder

JSON based replacement logging system for Ruby on Rails
MIT License
12 stars 8 forks source link

rake test fails - uninitialized constant Yarder::ActiveRecord #2

Closed drnic closed 11 years ago

drnic commented 11 years ago
> bundle exec rake test
/Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/inflector/methods.rb:230:in `block in constantize': uninitialized constant Yarder::ActiveRecord (NameError)
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/inflector/methods.rb:229:in `each'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/inflector/methods.rb:229:in `constantize'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/core_ext/string/inflections.rb:54:in `constantize'
    from /Users/drnic/Projects/gems/yarder/lib/yarder/railtie.rb:30:in `block (2 levels) in <class:Railtie>'
    from /Users/drnic/Projects/gems/yarder/lib/yarder/railtie.rb:29:in `each'
    from /Users/drnic/Projects/gems/yarder/lib/yarder/railtie.rb:29:in `block in <class:Railtie>'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/lazy_load_hooks.rb:34:in `call'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/lazy_load_hooks.rb:34:in `execute_hook'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/lazy_load_hooks.rb:43:in `block in run_load_hooks'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/lazy_load_hooks.rb:42:in `each'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/activesupport-3.2.8/lib/active_support/lazy_load_hooks.rb:42:in `run_load_hooks'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/application/finisher.rb:59:in `block in <module:Finisher>'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `instance_exec'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/initializable.rb:30:in `run'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/initializable.rb:55:in `block in run_initializers'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `each'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/initializable.rb:54:in `run_initializers'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/application.rb:136:in `initialize!'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/railties-3.2.8/lib/rails/railtie/configurable.rb:30:in `method_missing'
    from /Users/drnic/Projects/gems/yarder/test/dummy/config/environment.rb:5:in `<top (required)>'
    from /Users/drnic/Projects/gems/yarder/test/test_helper.rb:4:in `require'
    from /Users/drnic/Projects/gems/yarder/test/test_helper.rb:4:in `<top (required)>'
    from /Users/drnic/Projects/gems/yarder/test/yarder_test.rb:1:in `require'
    from /Users/drnic/Projects/gems/yarder/test/yarder_test.rb:1:in `<top (required)>'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:10:in `require'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:10:in `block (2 levels) in <main>'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:9:in `each'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:9:in `block in <main>'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:4:in `select'
    from /Users/drnic/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:4:in `<main>'
rake aborted!
Command failed with status (1): [/Users/drnic/.rvm/rubies/ruby-1.9.3-p194/b...]

Tasks: TOP => test
(See full trace by running task with --trace)
rurounijones commented 11 years ago

Yep, I noticed that last night but didn't get around to pushing the changes yet. It is due to some sillyness in the code.

Although as this is an experimental gem at the moment and testing this is way out of my usual testing setup there are no tests.

I am looking at how rails does LogSubscriber and Rack Logger testing.

rurounijones commented 11 years ago

fixed by 81c2fcc0cd4c8601eef7235762d2e182d9fa2d64

drnic commented 11 years ago

Cool. Alternate loggers are very interesting. But perhaps yarder + logstash will solve all our logging needs! :)