Sha256: 44aa5f22d104dc26c64ce0e0e9a96d443d7e44aa4c7590d161c1e1939ffd0110

Contents?: true

Size: 567 Bytes

Versions: 4

Compression:

Stored size: 567 Bytes

Contents

#!/usr/bin/env ruby
#
#  Created by Brent Rowland on 2008-01-26.
#  Copyright (c) 2008 Eidetic Software. All rights reserved.
#
# Eidetic PDF Test Helpers

def assert_array_in_delta(expected_floats, actual_floats, delta)
  expected_floats.each_with_index { |e, i| assert_in_delta(e, actual_floats[i], delta) }
end

def assert_close(expected, actual)
  if expected.respond_to?(:each_with_index) and actual.respond_to?(:[])
    expected.each_with_index { |e, i| assert_in_delta(e, actual[i], 2 ** -20) }
  else
    assert_in_delta(expected, actual, 2 ** -20)
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
eideticpdf-1.0.2 test/test_helpers.rb
eideticpdf-1.0.1 test/test_helpers.rb
eideticpdf-1.0.0 test/test_helpers.rb
eideticpdf-0.9.9 test/test_helpers.rb