fix problem with fdb_ranked:clear, enhance tests