Sha256: fef89801b65bc575d7871b5fc2b1b929b8e37bcdfb3a28ec187ef075061b031b

Contents?: true

Size: 505 Bytes

Versions: 14

Compression:

Stored size: 505 Bytes

Contents

module ActiveMocker

  module ActiveRecord

    module UnknownModule

      def include(_module)
        try_and_log('include', _module, caller)
      end

      def extend(_module)
        try_and_log('extend', _module, caller)
      end

      private

      def try_and_log(method, name, _caller)
        begin
          super _module
        rescue => e
          Config.logger.debug "#{method} module #{name} from class #{self.name}.\n  #{_caller}\n  #{e}"
        end
      end

    end

  end


end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
active_mocker-1.8.4 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.8.3 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.8.2 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.8.1 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.8 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.3 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.2 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.1 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.1rc lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7rc2 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.beta3 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.beta2 lib/active_mocker/active_record/unknown_module.rb
active_mocker-1.7.beta1 lib/active_mocker/active_record/unknown_module.rb