Class: Pact::NullExpectation

Inherits:
Object
  • Object
show all
Defined in:
lib/pact/shared/null_expectation.rb

Instance Method Summary collapse

Instance Method Details

#==(other_object) ⇒ Object



7
8
9
# File 'lib/pact/shared/null_expectation.rb', line 7

def ==(other_object)
 other_object.is_a? NullExpectation
end

#===(other_object) ⇒ Object



11
12
13
# File 'lib/pact/shared/null_expectation.rb', line 11

def ===(other_object)
 other_object.is_a? NullExpectation
end

#empty?Boolean

Returns:

  • (Boolean)


23
24
25
# File 'lib/pact/shared/null_expectation.rb', line 23

def empty?
  true
end

#eql?(other_object) ⇒ Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/pact/shared/null_expectation.rb', line 15

def eql?(other_object)
  self == other_object
end

#hashObject



19
20
21
# File 'lib/pact/shared/null_expectation.rb', line 19

def hash
  2934820948209428748274238642672
end

#nil?Boolean

Returns:

  • (Boolean)


27
28
29
# File 'lib/pact/shared/null_expectation.rb', line 27

def nil?
  true
end

#to_sObject



3
4
5
# File 'lib/pact/shared/null_expectation.rb', line 3

def to_s
  "<No expectation>"
end