fixed custom wait method in UI tests