Class: Erudite::Outcome

Inherits:
Object
  • Object
show all
Defined in:
lib/erudite/outcome.rb

Overview

Information about an expected or actual outcome.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(result, output) ⇒ Outcome

Returns a new instance of Outcome.



9
10
11
12
# File 'lib/erudite/outcome.rb', line 9

def initialize(result, output)
  @result = result
  @output = output
end

Instance Attribute Details

#outputObject (readonly)

Returns the value of attribute output.



7
8
9
# File 'lib/erudite/outcome.rb', line 7

def output
  @output
end

#resultObject (readonly)

Returns the value of attribute result.



6
7
8
# File 'lib/erudite/outcome.rb', line 6

def result
  @result
end

Instance Method Details

#==(other) ⇒ Object



14
15
16
17
# File 'lib/erudite/outcome.rb', line 14

def ==(other)
  result == other.result &&
    output == other.output
end