Class RR::WildcardMatchers::Boolean
In: lib/rr/wildcard_matchers/boolean.rb
Parent: Object

Methods

Public Instance methods

[Source]

    # File lib/rr/wildcard_matchers/boolean.rb, line 8
 8:       def ==(other)
 9:         other.is_a?(self.class)
10:       end
eql?(other)

Alias for #==

[Source]

    # File lib/rr/wildcard_matchers/boolean.rb, line 13
13:       def inspect
14:         'boolean'
15:       end

[Source]

   # File lib/rr/wildcard_matchers/boolean.rb, line 4
4:       def wildcard_match?(other)
5:         self == other || is_a_boolean?(other)
6:       end

Protected Instance methods

[Source]

    # File lib/rr/wildcard_matchers/boolean.rb, line 18
18:       def is_a_boolean?(subject)
19:         subject.is_a?(TrueClass) || subject.is_a?(FalseClass)
20:       end

[Validate]