Sha256: 64e413adda2eb6fe1e7e9dc855bf0e8160582886410520d1c49968d07c1e840c

Contents?: true

Size: 679 Bytes

Versions: 10

Compression:

Stored size: 679 Bytes

Contents

  #  _____         _
  # |_   _|__  ___| |_
  #   | |/ _ \/ __| __|
  #   | |  __/\__ \ |
  #   |_|\___||___/\__|
  #
  # for lib/facets/range/combine.rb
  #
  # Extracted Mon Sep 03 16:23:07 -0700 2007
  # w/ Test Extraction Ratchet
  #

 require 'facets/range/combine.rb'



  require 'test/unit'

  class TestRangeCombine < Test::Unit::TestCase

    def test_combine_ranges
      r = Range.combine(0..4, 2..6, 6..10, 13..17, 12..19)
      x = [0..10, 12..19]
      assert_equal(x, r)
    end

    def test_combine_arrays_as_intervals
      r = Range.combine([0, 4], [2, 6], [6, 10], [13, 17], [12, 19])
      x = [[0, 10], [12, 19]]
      assert_equal(x, r)
    end

  end



Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
facets-2.0.1 test/unit/range/test_combine.rb
facets-2.0.0 test/unit/range/test_combine.rb
facets-2.0.2 test/unit/range/test_combine.rb
facets-2.1.0 test/unit/range/test_combine.rb
facets-2.1.1 test/unit/range/test_combine.rb
facets-2.1.2 test/unit/range/test_combine.rb
facets-2.0.5 test/unit/range/test_combine.rb
facets-2.0.3 test/unit/range/test_combine.rb
facets-2.0.4 test/unit/range/test_combine.rb
facets-2.1.3 test/unit/range/test_combine.rb