Cover: Fix integration tests for ResizableBox via BlockPopover#49497
Merged
aaronrobertshaw merged 1 commit intotrunkfrom Mar 31, 2023
Merged
Cover: Fix integration tests for ResizableBox via BlockPopover#49497aaronrobertshaw merged 1 commit intotrunkfrom
aaronrobertshaw merged 1 commit intotrunkfrom
Conversation
andrewserong
approved these changes
Mar 31, 2023
Contributor
andrewserong
left a comment
There was a problem hiding this comment.
LGTM, this gets the Cover block tests passing locally 👍
If we run into any issues or conflicts with other tests, we could always move this to the cover block tests directly, and / or set it within a beforeAll and reset it in an afterAll.
Since this checks that it doesn't exist before mocking it, this LGTM! ✨
|
Size Change: 0 B Total Size: 1.34 MB ℹ️ View Unchanged
|
|
Flaky tests detected in 13aadc2. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/4571678342
|
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.
What?
Fixes broken Cover block tests after moving ResizableBox to BlockPopover.
Why?
Tests are failing on trunk.
How?
Adds a global mock for
window.DOMRect. kudos to @glendaviesnz for this fix.Testing Instructions
npm run test:unit packages/block-library/src/cover/test/edit.js