File tree Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Expand file tree Collapse file tree 2 files changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -584,10 +584,8 @@ def test_upsert(self):
584584 self .assertEqual (self .coll .find ({'x' : 2 }).count (), 0 )
585585
586586 def test_upsert_large (self ):
587- # We can insert a 16MB document, using an update command a little over
588- # 16MB long.
589587 client = self .coll .database .connection
590- big = 'a' * (client .max_bson_size - 30 )
588+ big = 'a' * (client .max_bson_size - 37 )
591589 bulk = self .coll .initialize_ordered_bulk_op ()
592590 bulk .find ({'x' : 1 }).upsert ().update ({'$set' : {'s' : big }})
593591 result = bulk .execute ()
Original file line number Diff line number Diff line change @@ -1859,7 +1859,7 @@ def test_insert_large_document(self):
18591859 self .assertRaises (DocumentTooLarge , self .db .test .update ,
18601860 {"bar" : "x" }, {"bar" : "x" * (max_size - 14 )}, w = 0 )
18611861 # This will pass with OP_UPDATE or the update command.
1862- self .db .test .update ({"bar" : "x" }, {"bar" : "x" * (max_size - 15 )})
1862+ self .db .test .update ({"bar" : "x" }, {"bar" : "x" * (max_size - 32 )})
18631863
18641864 def test_insert_large_batch (self ):
18651865 max_bson_size = self .client .max_bson_size
You can’t perform that action at this time.
0 commit comments