Sha256: f5c9fde4595cf6c10dbf27bce4c5a29fd0478bce34e15cdd026d71e0b7c0579a
Contents?: true
Size: 556 Bytes
Versions: 1
Compression:
Stored size: 556 Bytes
Contents
require 'spec/spec_helper' require 'taza/entity' describe Taza::Entity do it "should add methods for hash string keys" do entity = Taza::Entity.new({'apple' => 'pie'},nil) entity.should respond_to(:apple) end it "should be accessible like a hash(foo[:bar])" do entity = Taza::Entity.new({:apple => 'pie'},nil) entity[:apple].should eql('pie') end it "should be able to define methods for multiple levels" do entity = Taza::Entity.new({:fruits => {:apple => 'pie'} },nil) entity.fruits.apple.should eql('pie') end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
scudco-taza-0.8.5 | spec/entity_spec.rb |