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

[RNMobile] Add paused media state handlers to Android bridge code #57476

Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
573d7f0
Fix incorrect heading level in Editor curation docs (#57409)
ndiego Dec 28, 2023
970e925
NumberControl: Make increment and decrement buttons keyboard accessib…
afercia Dec 28, 2023
9c8001a
DataViews: update names for `DropdownMenuRadioItemCustom` (#57416)
oandregal Dec 28, 2023
3f6c738
Navigation Block: Use dom.focus for focus control (#57362)
t-hamano Dec 28, 2023
ec2c51d
DataViews: hide actions menu upon selecting a layout (#57418)
oandregal Dec 28, 2023
1f9b753
Server directive processing: Stop processing non-interactive blocks (…
cbravobernal Dec 28, 2023
1c79fd8
Performance: Avoid extra `useMarkPersistent` dispatch calls (#57435)
ntsekouras Dec 28, 2023
36396cc
Font Library: remove "has_font_mime_type" function (#57364)
HrithikDalal Dec 28, 2023
10facf1
Update modal description and button label (#57368)
HrithikDalal Dec 28, 2023
663916f
Update tutorial based on user feedback. (#57403)
ndiego Dec 28, 2023
83e1a2c
Change the slug for the theme.json doc to avoid conflicts (#57410)
ndiego Dec 28, 2023
6f6b083
Migrate 'allowed patterns' e2e tests to Playwright (#57399)
Mamaduka Dec 29, 2023
3591f4d
DataViews: fallback to `(no title)` if there's no rendered title (#57…
oandregal Dec 29, 2023
b85da47
DataViews: make fields dependant on view.type (#57450)
oandregal Dec 29, 2023
af8c530
DataViews: prevent unnecessary re-renders (#57452)
oandregal Dec 29, 2023
2888084
Docs/tutorial: Fix opposite condition for content generation in rende…
atachibana Dec 29, 2023
2dbd8a5
DataViews: prevent unnecessary renders for Pagination (#57454)
oandregal Dec 29, 2023
0d2bf01
Make the Replace featured image button perceivable by assistive techn…
afercia Dec 29, 2023
9431114
DataViews: memoize onSetSelection (#57458)
oandregal Dec 29, 2023
63a6321
Fix Template preview menu item accessibility. (#57456)
afercia Dec 30, 2023
fc36077
Migrate 'preferences' e2e tests to Playwright (#57446)
Mamaduka Dec 30, 2023
a87f24e
Migrate remaining 'publish panel' e2e tests to Playwright (#57432)
Mamaduka Jan 1, 2024
06b5fa5
Core Data: Pass the 'options' argument to data action shortcuts (#57383)
Mamaduka Jan 1, 2024
4eb3b74
Editor: Unify the DocumentTools component (#57214)
youknowriad Jan 1, 2024
18dd101
Avoid using a memoized selector without dependencies (#57257)
youknowriad Jan 1, 2024
1014dc6
Quality: avoid React warning when changing rendering mode (#57413)
t-hamano Jan 1, 2024
31e67ea
Global style revisions: move change summary code and tests to block e…
ramonjd Jan 2, 2024
5831320
Adding padding to entity save panel header (#57471)
ramonjd Jan 2, 2024
3c80f02
use a classname instead of the element in case a strong element is pa…
ramonjd Jan 2, 2024
f70554c
Passed progress values to failed media uploads and add paused media h…
derekblank Jan 2, 2024
2d43054
Migrate 'sidebar' e2e tests to Playwright (#57448)
Mamaduka Jan 2, 2024
0aabb54
Add onMediaFileSavePaused handler
derekblank Jan 2, 2024
f364b68
[RNMobile] Auto-scroll upon block insertion (#57273)
fluiddot Jan 2, 2024
9e0747e
Add individual headings to the elements translations (#57472)
ramonjd Jan 2, 2024
7ebb55c
DataViews: Use in patterns page (#57333)
ntsekouras Jan 2, 2024
1ed7ba2
[Mobile] Unselect blocks using the hardware back button (Android) (#5…
Jan 2, 2024
50a8314
Remove deprecated `behaviors` syntax (#57165)
michalczaplinski Jan 2, 2024
60bf21e
Add `compact` size variant to InputControl-based components (#57398)
mirka Jan 2, 2024
1b2dac7
Block editor: give iframe fallback background color (#57330)
ramonjd Jan 2, 2024
45dc4b1
Background image block support: Add tests for size and repeat output …
andrewserong Jan 2, 2024
78f28c1
Update paused handlers from merge
derekblank Jan 3, 2024
a33a090
Merge branch 'rnmobile/media-upload-progress-connection-subscription'…
derekblank Jan 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Migrate 'sidebar' e2e tests to Playwright (#57448)
* Migrate 'sidebar' e2e  tests to Playwright

* Remove old test file
  • Loading branch information
Mamaduka authored Jan 2, 2024
commit 2d43054e0343cfdc9c3ad9d055e8ba23d2979b34
171 changes: 0 additions & 171 deletions packages/e2e-tests/specs/editor/various/sidebar.test.js

This file was deleted.

136 changes: 136 additions & 0 deletions test/e2e/specs/editor/various/sidebar.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
/**
* WordPress dependencies
*/
const { test, expect } = require( '@wordpress/e2e-test-utils-playwright' );

test.describe( 'Sidebar', () => {
test.beforeAll( async ( { requestUtils } ) => {
// The test expects clean user preferences.
await requestUtils.resetPreferences();
} );

test.beforeEach( async ( { admin } ) => {
await admin.createNewPost();
} );

test( 'should have sidebar visible at the start with document sidebar active on desktop', async ( {
page,
pageUtils,
} ) => {
await pageUtils.setBrowserViewport( 'large' );

const activeTab = page
.getByRole( 'region', {
name: 'Editor settings',
} )
.getByRole( 'tab', { selected: true } );

await expect( activeTab ).toBeVisible();
await expect( activeTab ).toHaveText( 'Post' );
} );

test( 'should have the sidebar closed by default on mobile', async ( {
page,
pageUtils,
} ) => {
await pageUtils.setBrowserViewport( 'small' );

await expect(
page.getByRole( 'region', {
name: 'Editor settings',
} )
).toBeHidden();
} );

test( 'should close the sidebar when resizing from desktop to mobile', async ( {
page,
pageUtils,
} ) => {
await pageUtils.setBrowserViewport( 'large' );
const settingsSideber = page.getByRole( 'region', {
name: 'Editor settings',
} );

await expect( settingsSideber ).toBeVisible();

await pageUtils.setBrowserViewport( 'small' );

// Sidebar should be closed when resizing to mobile.
await expect( settingsSideber ).toBeHidden();
} );

test( 'should reopen sidebar the sidebar when resizing from mobile to desktop if the sidebar was closed automatically', async ( {
page,
pageUtils,
} ) => {
await pageUtils.setBrowserViewport( 'large' );
await pageUtils.setBrowserViewport( 'small' );
const settingsSideber = page.getByRole( 'region', {
name: 'Editor settings',
} );

await expect( settingsSideber ).toBeHidden();
await pageUtils.setBrowserViewport( 'large' );
await expect( settingsSideber ).toBeVisible();
} );

test( 'should preserve tab order while changing active tab', async ( {
page,
pageUtils,
} ) => {
// Region navigate to Sidebar.
await pageUtils.pressKeys( 'ctrl+`' );

// Tab lands at first (presumed selected) option "Post".
await page.keyboard.press( 'Tab' );

const activeTab = page
.getByRole( 'region', {
name: 'Editor settings',
} )
.getByRole( 'tab', { selected: true } );

// The Post tab should be focused and selected.
await expect( activeTab ).toHaveText( 'Post' );
await expect( activeTab ).toBeFocused();

// Arrow key into and activate "Block".
await page.keyboard.press( 'ArrowRight' );
await page.keyboard.press( 'Space' );

// The Block tab should be focused and selected.
await expect( activeTab ).toHaveText( 'Block' );
await expect( activeTab ).toBeFocused();
} );

test( 'should be possible to programmatically remove Document Settings panels', async ( {
page,
} ) => {
const documentSettingsPanels = page
.getByRole( 'tabpanel', { name: 'Post' } )
.getByRole( 'heading', { level: 2 } );

await expect( documentSettingsPanels ).toHaveText( [
'Summary',
'Categories',
'Tags',
'Featured image',
'Excerpt',
'Discussion',
] );

await page.evaluate( () => {
const { removeEditorPanel } =
window.wp.data.dispatch( 'core/editor' );

removeEditorPanel( 'taxonomy-panel-category' );
removeEditorPanel( 'taxonomy-panel-post_tag' );
removeEditorPanel( 'featured-image' );
removeEditorPanel( 'post-excerpt' );
removeEditorPanel( 'discussion-panel' );
removeEditorPanel( 'post-status' );
} );

await expect( documentSettingsPanels ).toHaveCount( 0 );
} );
} );
Loading