Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix flaky upload tests. #313

Merged

Conversation

NorberMV
Copy link
Contributor

@NorberMV NorberMV commented Oct 25, 2023

This PR fixes flaky tests that contain the following errors:

- AssertionError: 'image/png' != 'image/jpeg'
- AssertionError: '304' != '200'

Allows upload requests with status '304' in the thumbnail upload tests, because sometimes when the response hasn't been modified, this status informs the client that the response has not changed, so the client can continue using the same cached version.

Also supports transient placeholder PNG file content types in the response payload, since sometimes it takes longer for the previously uploaded image requested to be available from media storage, and we have previously tested that the image was successfully uploaded.

@NorberMV NorberMV marked this pull request as ready for review October 26, 2023 14:47
Copy link
Contributor

@carlos-villavicencio-adsk carlos-villavicencio-adsk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM :shipit:

@NorberMV NorberMV merged commit 9ade6cf into master Oct 26, 2023
21 checks passed
@NorberMV NorberMV deleted the SG-30485_Flaky_Thumbnail_Related_Tests_On_Python_Api branch October 26, 2023 15:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants