Sha256: a75f8ba1d1928e2e75cf201a755e55ecf8e6854f5c8a59115097aac1dd33930f

Contents?: true

Size: 396 Bytes

Versions: 16

Compression:

Stored size: 396 Bytes

Contents

#!/usr/bin/env ruby

require File.join(File.dirname(__FILE__), '_common.rb')
db = Mongo.new(DEFAULT_HOST, DEFAULT_PORT).db(DEFAULT_DB)
foo = db.collection('foo')

if $DEBUG
  foo.drop
  foo.insert(:x => 1)
end

foo.modify({:x => 1}, {:x => 1, :y => 2})
foo.modify({:x => 2}, {:x => 1, :y => 7})
foo.repsert({:x => 3}, {:x => 4, :y => 1})

if $DEBUG
  foo.find.each { |row| puts row.inspect }
end

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
animehunter-mongo-0.9 tests/mongo-qa/update
mongodb-mongo-0.10.1 tests/mongo-qa/update
mongodb-mongo-0.10 tests/mongo-qa/update
mongodb-mongo-0.11.1 tests/mongo-qa/update
mongodb-mongo-0.11 tests/mongo-qa/update
mongodb-mongo-0.12 tests/mongo-qa/update
mongodb-mongo-0.6.1 tests/mongo-qa/update
mongodb-mongo-0.6.2 tests/mongo-qa/update
mongodb-mongo-0.6.3 tests/mongo-qa/update
mongodb-mongo-0.6.4 tests/mongo-qa/update
mongodb-mongo-0.6.5 tests/mongo-qa/update
mongodb-mongo-0.6.6 tests/mongo-qa/update
mongodb-mongo-0.6.7 tests/mongo-qa/update
mongodb-mongo-0.7 tests/mongo-qa/update
mongodb-mongo-0.8 tests/mongo-qa/update
mongodb-mongo-0.9 tests/mongo-qa/update