Sha256: b5fccfea2773ea011250983336a5a10bdc1a18f71f131e949bdb296b8955624e

Contents?: true

Size: 640 Bytes

Versions: 1

Compression:

Stored size: 640 Bytes

Contents

#  _____         _
# |_   _|__  ___| |_
#   | |/ _ \/ __| __|
#   | |  __/\__ \ |_
#   |_|\___||___/\__|
#
# for lib/facet/hash/alias.rb
#
# Extracted Wed Jan 25 11:25:39 EST 2006
# Unit Tools Reap Test Extractor
#

require 'facet/hash/alias.rb'


  require 'test/unit'

  class TCHash < Test::Unit::TestCase

    def test_alias!
      foo = { 'a'=>1, 'b'=>2 }
      assert_equal( { 'a'=>1, 'b'=>2, 'c'=>2 }, foo.alias!('c','b') )
      foo = { 'a'=>1, 'b'=>2 }
      assert_equal( { :a=>1, 'a'=>1, 'b'=>2 }, foo.alias!(:a,'a') )
      foo = { :a=>1, :b=>2 }
      assert_equal( { :a=>1, :b=>2 }, foo.alias!('bar','foo') )
    end

  end


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
facets-1.0.3 packages/core/test/lib/facet/hash/test_alias.rb