Sha256: 91e37b37001962b6a1d603e76d7f8e6350e9f2df0a90938a94a2f17476b2aad7

Contents?: true

Size: 254 Bytes

Versions: 16

Compression:

Stored size: 254 Bytes

Contents

require 'facets/numeric/distance.rb'
require 'test/unit'

class TestNumericDistance < Test::Unit::TestCase

  def test_distance
    assert_equal( 4, 10.distance(6) )
    assert_equal( 2, 10.distance(8) )
    assert_equal( -2, 7.distance(9) )
  end

end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
facets-2.8.4 test/core/numeric/test_distance.rb
facets-2.8.3 test/core/numeric/test_distance.rb
facets-2.8.2 test/core/numeric/test_distance.rb
facets-2.8.1 test/core/numeric/test_distance.rb
facets-2.8.0 test/core/numeric/test_distance.rb
facets-2.7.0 test/core/numeric/test_distance.rb
facets-2.6.0 test/core/numeric/test_distance.rb
facets-2.4.0 test/numeric/test_distance.rb
facets-2.4.1 test/numeric/test_distance.rb
facets-2.4.4 test/core/numeric/test_distance.rb
facets-2.4.3 test/core/numeric/test_distance.rb
facets-2.4.2 test/core/numeric/test_distance.rb
facets-2.5.1 test/core/numeric/test_distance.rb
facets-2.4.5 test/core/numeric/test_distance.rb
facets-2.5.0 test/core/numeric/test_distance.rb
facets-2.5.2 test/core/numeric/test_distance.rb