Test and fix dialog boxes so they close