Fix various tests for mongos and old mongo versions.