Sha256: d6066afdd715bbca24c040e70c7a552d7bf0fba377e627ba727567252a307b00
Contents?: true
Size: 489 Bytes
Versions: 53
Compression:
Stored size: 489 Bytes
Contents
module FactoryGirl # @api private class NullObject < ::BasicObject def initialize(methods_to_respond_to) @methods_to_respond_to = methods_to_respond_to.map(&:to_s) end def method_missing(name, *args, &block) if respond_to?(name) nil else super end end def respond_to?(method, include_private=false) @methods_to_respond_to.include? method.to_s end def respond_to_missing?(*args) false end end end
Version data entries
53 entries across 41 versions & 11 rubygems