-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Writing Flow: Fix copy pasting non textual blocks #30225
Conversation
@@ -31,6 +31,17 @@ describe( 'Copy/cut/paste of whole blocks', () => { | |||
expect( await getEditedPostContent() ).toMatchSnapshot(); | |||
} ); | |||
|
|||
it( 'should copy blocks when non textual elements are focused (image, spacer)', async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added a test but the weird thing is that the test pass on trunk even if it fails when you do the same thing manually. I was not able to make the test fail in trunk no matter how I tried to write it.
Size Change: +18 B (0%) Total Size: 1.41 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change itself makes total sense. It's only weird that we can't get the E2E to fail when it should.
If you insert an image, or a spacer and click on it then try to copy it using "cmd + c", you'll notice in trunk that it's not copied (at least not consistently) depending on what element of the block is focused.
This PR fixes that bug.