Can I log to test.log with rspec?

Viewed 1293

Here's a simple spec just to test this:

require 'spec_helper'
describe A_controller do
    before do
         @cat_noise = "Meow"
    end
    it "should do nothing because it's empty and I created it just to test logger!" do
       logger.info "---------- Here comes a cat noise -----------"
       logger.info @cat_noise
       logger.info "-----------There goes a cat noise -----------"
    end
end

And here's my log level configuration for the test environment:

  config.log_level = :info

However, I'm getting nothing to do with cat noises in my test.log file. Should I be? Would it appear in test.log? It would be good to double check factories and the like...

1 Answers
Related