123456789_123456789_123456789_123456789_123456789_

Class: Test::Unit::Assertions::AssertionMessage::NumericInspector

Relationships & Source Files
Inherits: Object
Defined in: lib/test/unit/assertions.rb

Class Method Summary

Instance Method Summary

Constructor Details

.new(numeric, inspected_objects) ⇒ NumericInspector

[ GitHub ]

  
# File 'lib/test/unit/assertions.rb', line 1878

def initialize(numeric, inspected_objects)
  @inspected_objects = inspected_objects
  @numeric = numeric
end

Class Method Details

.target?(object) ⇒ Boolean

[ GitHub ]

  
# File 'lib/test/unit/assertions.rb', line 1873

def target?(object)
  object.is_a?(Numeric)
end

Instance Method Details

#inspect

[ GitHub ]

  
# File 'lib/test/unit/assertions.rb', line 1883

def inspect
  @numeric.to_s
end

#pretty_print(q)

[ GitHub ]

  
# File 'lib/test/unit/assertions.rb', line 1887

def pretty_print(q)
  q.text(@numeric.to_s)
end

#pretty_print_cycle(q)

[ GitHub ]

  
# File 'lib/test/unit/assertions.rb', line 1891

def pretty_print_cycle(q)
  q.text(@numeric.to_s)
end