Sha256: f67cd6a7f1bc3e65dc21baad4b67beeadee6504b86f8f3367089058ab9f81d07
Contents?: true
Size: 450 Bytes
Versions: 2
Compression:
Stored size: 450 Bytes
Contents
require 'helper' class OpenStructTest < Test::Unit::TestCase def from_db UserConfig.find(@config.id) end context "working with sets" do setup do @config = UserConfig.create!() end should "allow to add new keys" do entries = MongoidExt::OpenStruct.new() entries.new_key = "my new key" @config.entries = entries @config.save from_db.entries.new_key.should == "my new key" end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mongoid_ext-0.9.0 | test/types/test_open_struct.rb |
mongoid_ext-0.7.1 | test/types/test_open_struct.rb |