Class: Expectation::MultiMatcher

Inherits:
Array
  • Object
show all
Defined in:
lib/expectation/multi_matcher.rb

Overview

The Expectation::MultiMatcher class provides support for T1 | T2 matches.

Instance Method Summary collapse

Constructor Details

#initialize(lhs, rhs) ⇒ MultiMatcher

Returns a new instance of MultiMatcher.



11
12
13
14
# File 'lib/expectation/multi_matcher.rb', line 11

def initialize(lhs, rhs)
  push lhs
  push rhs
end

Instance Method Details

#|(other) ⇒ Object



16
17
18
# File 'lib/expectation/multi_matcher.rb', line 16

def |(other)
  push other
end