Fixes flakey test in integration upload dropzone field
What does this MR do and why?
This MR fixes flakey tests around the UploadDropzoneField used by the Apple App Store and Google Play integrations.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
How to set up and validate locally
This flakey test is caused by a readFile
method in upload_dropzone_field.vue
.
I replicated this locally by adding a setTimeout around file reader, for example:
readFile(file) {
let that = this
setTimeout(function(){
const reader = new FileReader();
reader.readAsText(file);
reader.onload = (evt) => {
that.fileContents = evt.target.result;
};
}, 2000);
},
This change will cause the test to fail in the previous state, and pass with the update capybara selectors.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.