Sha256: 36f1665738975a1c75ec925134699c25e7995da5879c4250d5d9b737ae9cda37

Contents?: true

Size: 443 Bytes

Versions: 5

Compression:

Stored size: 443 Bytes

Contents

module Webrat
  module Logging #:nodoc:

    def warn_log(message) # :nodoc:
      return unless logger
      logger.warn message
    end
    
    def debug_log(message) # :nodoc:
      return unless logger
      logger.debug message
    end

    def logger # :nodoc:
      if defined? RAILS_DEFAULT_LOGGER
        RAILS_DEFAULT_LOGGER
      elsif defined? Merb
        Merb.logger        
      else
        nil
      end
    end
  
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
webrat-0.3.0 lib/webrat/core/logging.rb
webrat-0.3.2 lib/webrat/core/logging.rb
webrat-0.3.3 lib/webrat/core/logging.rb
webrat-0.3.1 lib/webrat/core/logging.rb
webrat-0.3.4 lib/webrat/core/logging.rb