[deliver] Resolves issue uploading iPad Pro 5th gen screenshots #19616
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Checklist
bundle exec rspec
from the root directory to see all new and existing tests passbundle exec rubocop -a
to ensure the code style is validMotivation and Context
I experienced the same issue as described in #16262 but for iPad Pro 12.9 (5th Gen.): screenshots of the 5th gen. are uploaded into the slot of the 2nd gen. iPad Pro 12.9 inch.
This can be fixed in the same way as in #16288.
Description
The problem was in resolve_ipadpro_conflict_if_needed() function which uses simulator name to resolve conflicts (2nd gen/3rd/4th/5th gens have the same screen size). I added new simulator name to the list.
Testing Steps
Added new unit tests to the app_screenshot_spec.rb, to recognize this corner case.
Run
bundle exec rspec deliver/spec/app_screenshot_spec.rb
to test.To test in real world, you need to have a project with screenshots made on 2nd and 5th gens iPad Pros 12.9" simulators. There is no need to submit screenshots to the App Store, preview html clearly shows the issues.