[RNMobile] Update "testAddGalleryBlock" test case to reflect expected content for v1 of Gallery block#18898
Merged
dcalhoun merged 1 commit intogutenberg/integrate_release_1.78.1from Jun 16, 2022
Conversation
Generated by 🚫 dangerJS |
Contributor
You can test the changes in Jetpack from this Pull Request by:
|
Contributor
You can test the changes in WordPress from this Pull Request by:
|
dcalhoun
approved these changes
Jun 16, 2022
Member
dcalhoun
left a comment
There was a problem hiding this comment.
The outline problem and solution make sense to me. Thank for addressing this. 🚀
7 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
After we re-introduced support for v1 of the Gallery block in WordPress/gutenberg#41533, the
testAddGalleryBlocktest case within iOS'EditorGutenbergTestsfile began to fail with the following error:The reason for this is that v1 is used by default when no API is mocked. Unlike v2 of the Gallery block, v1 doesn't use additional inner blocks when images are used. As additional blocks aren't added to the editor when images are uploaded to v1 of the block, the number of expected blocks has changed:
This PR updates
verifyContentStructureto reflect the fact we currently only expected 2 blocks whentestAddGalleryBlockruns.In the future, we may seek to mock an API request and update the test case to expect v2 of the Gallery block. We're going with this simpler solution for now in order to move forward with others PRs and address the failing test.
Testing
To test: Verify that all tests pass on this PR, with no failures.
Regression Notes
I'm not aware of other areas of the code base that could be impacted by this change, though it's possible that other tests may rely on the
testAddGalleryBlockcase somehow.Ensured all tests pass for this PR.
N/A
PR submission checklist:
RELEASE-NOTES.txtif necessary.