Sha256: aaf08af82735722ce962b76e345713c2f5ea11bb82a782bb4f8abbc0ceb435fb
Contents?: true
Size: 669 Bytes
Versions: 1
Compression:
Stored size: 669 Bytes
Contents
require 'test/unit' require 'methodic_hash' class TC_MethodicHash < Test::Unit::TestCase def test_accesses mh = MethodicHash.new assert((mh['one'] = 1) == 1) assert(mh['one'] == 1) assert(mh[:one] == 1) assert(mh.one == 1) assert((mh[:two] = 2) == 2) assert(mh['two'] == 2) assert(mh[:two] == 2) assert(mh.two == 2) assert(mh['three'] == nil) assert(mh[:three] == nil) assert(mh.three == nil) assert((mh.four = 4) == 4) assert(mh['four'] == 4) assert(mh[:four] == 4) assert(mh.four == 4) assert(mh[1.25] == nil) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
eymiha_util-0.1.3 | test/tc_methodic_hash.rb |