
db = connect( "tests" ); 

t1 = db.table1; 
t2 = db.table2; 

o1 = {a: 'a', b: "b"}; 
o2 = {e: 'e', o: o1}; 

t1.save(o1); 
t2.save(o2); 

o1 = null; 
o2 = null; 
o2 = t2.findOne(); 

assert( "a" == o2.o.a);
assert( "b" == o2.o.b); 

o1 = o2.o; 
o1.a = "c"; 

delete o1._id; 
delete o1._ns; 

db.asd.save( o1 );



@@ -52,24 +52,59 @@
 b.table2; %0A%0A
+t1.remove( %7B%7D );%0At2.remove( %7B%7D );%0A%0A
 o1 = %7Ba: 'a'
@@ -164,24 +164,44 @@
 save(o2); %0A%0A
+origo1id = o1._id;%0A%0A
 o1 = null; %0A
@@ -233,16 +233,40 @@
 ne(); %0A%0A
+print( tojson( o2 ) );%0A%0A
 assert( 
@@ -337,56 +337,154 @@
 ; %0A%0A
-delete o1
+t2.save(o2);%0A%0Aassert( t2.findOne( o2
 ._id
-; %0Adelete o1._ns; %0A%0Adb.asd.save( o1
+ ).o.a == %22c%22 );%0Aassert( t2.findOne( o2._id ).o._id == origo1id );%0Aassert( t1.findOne( origo1id ).a == %22c%22
  );%0A

make test better