summaryrefslogtreecommitdiff
path: root/jstests/core/dbref1.js
blob: 4a827662c1aba0cd207e4d69c302458dc51f0c66 (plain)
1
2
3
4
5
6
7
8
9
10

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" );