Permalink
Browse files

test for SERVER-567

  • Loading branch information...
1 parent 969f8df commit c4388ac021d74c7cbce90cee15ffc8e0e0d6e02b @erh erh committed Jan 26, 2010
Showing with 14 additions and 0 deletions.
  1. +14 −0 jstests/updatec.js
View
@@ -0,0 +1,14 @@
+
+t = db.updatec;
+t.drop();
+
+t.update( { "_id" : 123 }, { $set : { "v" : { "i" : 123, "a":456 } }, $push : { "f" : 234} }, 1, 0 );
+t.update( { "_id" : 123 }, { $set : { "v" : { "i" : 123, "a":456 } }, $push : { "f" : 234} }, 1, 0 );
+
+assert.eq(
+ {
+ "_id" : 123,
+ "f" : [ 234, 234 ] ,
+ "v" : { "i" : 123, "a" : 456 }
+ } , t.findOne() );
+

0 comments on commit c4388ac

Please sign in to comment.