mirror of
https://github.com/mongodb/mongo.git
synced 2024-12-01 01:21:03 +01:00
11 lines
203 B
JavaScript
11 lines
203 B
JavaScript
|
|
a = db.dbref1a;
|
|
b = db.dbref1b;
|
|
|
|
a.drop();
|
|
b.drop();
|
|
|
|
a.save({name: "eliot"});
|
|
b.save({num: 1, link: new DBPointer("dbref1a", a.findOne()._id)});
|
|
assert.eq("eliot", b.findOne().link.fetch().name, "A");
|