Fix bug 987275 - Make test_deleted_items more resistant against timing issues. r=mschroeder