Class: Duckface::ParameterPair

Inherits:
Object
  • Object
show all
Defined in:
lib/duckface/parameter_pair.rb

Overview

Takes a method parameters and prepares them for comparison

Instance Method Summary collapse

Constructor Details

#initialize(parameter_pair) ⇒ ParameterPair

Returns a new instance of ParameterPair.



6
7
8
# File 'lib/duckface/parameter_pair.rb', line 6

def initialize(parameter_pair)
  @parameter_pair = parameter_pair
end

Instance Method Details

#for_comparisonObject



10
11
12
# File 'lib/duckface/parameter_pair.rb', line 10

def for_comparison
  [@parameter_pair.first, argument_name_without_leading_underscore]
end