added jstests for SERVER-7511 fix.