Sha256: f592d060adab4edfdaf747bc12445ef95c5fd7cbc2bf87d254d3d4080d41965f
Contents?: true
Size: 692 Bytes
Versions: 1
Compression:
Stored size: 692 Bytes
Contents
# _____ _ # |_ _|__ ___| |_ # | |/ _ \/ __| __| # | | __/\__ \ |_ # |_|\___||___/\__| # # for lib/facets/core/hash/normalize_keys.rb # # Extracted Fri Feb 16 02:00:36 EST 2007 # Project.rb Test Extraction # require 'facets/core/hash/normalize_keys.rb' require 'test/unit' class TestHash < Test::Unit::TestCase def test_01 foo = { :a=>1, :b=>2 } assert_equal( { "a"=>1, "b"=>2 }, foo.normalize_keys{|k|k.to_s} ) assert_equal( { :a =>1, :b=>2 }, foo ) end def test_02 foo = { :a=>1, :b=>2 } assert_equal( { "a"=>1, "b"=>2 }, foo.normalize_keys!{|k|k.to_s} ) assert_equal( { "a"=>1, "b"=>2 }, foo ) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
facets-1.8.49 | test/lib/facets/core/hash/test_normalize_keys.rb |