Add a few missing cascade-deletes
Fix test broken due to delete_record change