diff --git a/.github/workflows/run-test-and-deploy.yml b/.github/workflows/run-test-and-deploy.yml
index e1974ae2..5a403859 100644
--- a/.github/workflows/run-test-and-deploy.yml
+++ b/.github/workflows/run-test-and-deploy.yml
@@ -12,9 +12,17 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
- php-versions: [ '7.3', '7.4', '8.0' ]
- wp-versions: [ 'WordPress#5.9.4', 'WordPress#6.0.3' ]
- # wp-versions: [ 'WordPress#5.9.4', 'WordPress#6.0.3', 'WordPress' ]
+ php-versions: [
+ '7.3',
+ '7.4',
+ '8.0'
+ ]
+ wp-versions: [
+ 'WordPress#5.9.4',
+ 'WordPress#6.0.3',
+ 'WordPress#6.1',
+ 'WordPress'
+ ]
name: PHP ${{ matrix.php-versions }} / ${{ matrix.wp-versions }} Test
steps:
diff --git a/.github/workflows/run-test.yml b/.github/workflows/run-test.yml
index 70b50629..a4b98f04 100644
--- a/.github/workflows/run-test.yml
+++ b/.github/workflows/run-test.yml
@@ -15,9 +15,17 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
- php-versions: [ '7.3', '7.4', '8.0' ]
- wp-versions: [ 'WordPress#5.9.4', 'WordPress#6.0.3' ]
- # wp-versions: [ 'WordPress#5.9.4', 'WordPress#6.0.3', 'WordPress' ]
+ php-versions: [
+ '7.3',
+ '7.4',
+ '8.0'
+ ]
+ wp-versions: [
+ 'WordPress#5.9.4',
+ 'WordPress#6.0.3',
+ 'WordPress#6.1',
+ 'WordPress'
+ ]
name: PHP ${{ matrix.php-versions }} / ${{ matrix.wp-versions }} Test
steps:
diff --git a/package-lock.json b/package-lock.json
index 9f5ddfde..7eaab1ad 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -21,7 +21,7 @@
"@typescript-eslint/eslint-plugin": "^5.40.0",
"@typescript-eslint/parser": "^5.40.0",
"@wordpress/e2e-test-utils": "^8.3.0",
- "@wordpress/env": "^5.4.0",
+ "@wordpress/env": "^5.5.0",
"@wordpress/jest-preset-default": "^10.0.0",
"@wordpress/jest-puppeteer-axe": "^5.2.0",
"@wordpress/scripts": "^24.3.0",
@@ -5647,9 +5647,9 @@
}
},
"node_modules/@wordpress/env": {
- "version": "5.4.0",
- "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-5.4.0.tgz",
- "integrity": "sha512-5vrOlTQ3kr15qQP5V1ObloRrsAx/UjKzbCUnrKFqaCCPxEiS+VnyJ+TCCHerKGwQUEKroX4iBd4cdbZniCChGw==",
+ "version": "5.5.0",
+ "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-5.5.0.tgz",
+ "integrity": "sha512-Dm/XHkCD8rVSfm9fGvK92EbfZ7UhZCkIoNdv8wq21cwiZ0/2O0iPaC73aJ/4pTaY0PBODz5Z/LD4gE/cRSDcxg==",
"dev": true,
"dependencies": {
"chalk": "^4.0.0",
@@ -26648,9 +26648,9 @@
}
},
"@wordpress/env": {
- "version": "5.4.0",
- "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-5.4.0.tgz",
- "integrity": "sha512-5vrOlTQ3kr15qQP5V1ObloRrsAx/UjKzbCUnrKFqaCCPxEiS+VnyJ+TCCHerKGwQUEKroX4iBd4cdbZniCChGw==",
+ "version": "5.5.0",
+ "resolved": "https://registry.npmjs.org/@wordpress/env/-/env-5.5.0.tgz",
+ "integrity": "sha512-Dm/XHkCD8rVSfm9fGvK92EbfZ7UhZCkIoNdv8wq21cwiZ0/2O0iPaC73aJ/4pTaY0PBODz5Z/LD4gE/cRSDcxg==",
"dev": true,
"requires": {
"chalk": "^4.0.0",
diff --git a/package.json b/package.json
index 971de068..997a48a6 100644
--- a/package.json
+++ b/package.json
@@ -29,7 +29,7 @@
"@typescript-eslint/eslint-plugin": "^5.40.0",
"@typescript-eslint/parser": "^5.40.0",
"@wordpress/e2e-test-utils": "^8.3.0",
- "@wordpress/env": "^5.4.0",
+ "@wordpress/env": "^5.5.0",
"@wordpress/jest-preset-default": "^10.0.0",
"@wordpress/jest-puppeteer-axe": "^5.2.0",
"@wordpress/scripts": "^24.3.0",
diff --git a/test/e2e/specs/block-support.test.ts b/test/e2e/specs/block-support.test.ts
index 3e04e061..25af657f 100644
--- a/test/e2e/specs/block-support.test.ts
+++ b/test/e2e/specs/block-support.test.ts
@@ -31,7 +31,7 @@ describe( 'Block Support', () => {
await createNewFlexibleTableBlock();
await openSidebar();
- if ( wpVersion === '6-1' ) {
+ if ( [ '6-1', '6-2' ].includes( wpVersion ) ) {
await toggleToolsPanelMenu();
for ( let i = 0; i < 6; i++ ) {
const selector = 'div[aria-label="Typography options"] button.components-menu-item__button';
@@ -51,7 +51,7 @@ describe( 'Block Support', () => {
}
}
- const fontFamilyLabel = wpVersion === '6-1' ? 'Font' : 'Font family';
+ const fontFamilyLabel = [ '6-1', '6-2' ].includes( wpVersion ) ? 'Font' : 'Font family';
await selectOptionFromLabel( fontFamilyLabel, '"Source Serif Pro", serif' );
await clickButtonWithAriaLabel( '.components-font-size-picker', 'Large' );
await clickButtonWithAriaLabel( '.typography-block-support-panel', 'Appearance' );
@@ -64,7 +64,7 @@ describe( 'Block Support', () => {
await inputValueFromLabel( 'Line height', '3' );
await clickButtonWithAriaLabel( '.typography-block-support-panel', 'Lowercase' );
- if ( wpVersion === '6-1' ) {
+ if ( [ '6-1', '6-2' ].includes( wpVersion ) ) {
await inputValueFromLabel( 'Letter spacing', '10' );
} else {
await page.focus( 'input[aria-label="Letter-spacing"], input[aria-label="Letter spacing"]' );
@@ -72,12 +72,11 @@ describe( 'Block Support', () => {
}
// WordPress 6.1 has a different inline style order generated by block support
- const snapShot =
- wpVersion === '6-1'
- ? `
+ const snapShot = [ '6-1', '6-2' ].includes( wpVersion )
+ ? `
`
- : `
+ : `
`;
@@ -91,10 +90,12 @@ describe( 'Block Support', () => {
await openSidebar();
await toggleToolsPanelMenu( 'dimensions' );
await page.click( `button[aria-label="Show Margin"]` );
- const unlinkSidesLabel = wpVersion === '6-1' ? 'Unlink sides' : 'Unlink Sides';
+ const unlinkSidesLabel = [ '6-1', '6-2' ].includes( wpVersion )
+ ? 'Unlink sides'
+ : 'Unlink Sides';
await clickButtonWithAriaLabel( '.dimensions-block-support-panel', unlinkSidesLabel );
- if ( wpVersion === '6-1' ) {
+ if ( [ '6-1', '6-2' ].includes( wpVersion ) ) {
for ( let i = 0; i < 4; i++ ) {
await clickButtonWithAriaLabel( '.dimensions-block-support-panel', 'Set custom size' );
}
diff --git a/test/e2e/specs/transform.test.ts b/test/e2e/specs/transform.test.ts
index b78f5a8c..5e2e93e7 100644
--- a/test/e2e/specs/transform.test.ts
+++ b/test/e2e/specs/transform.test.ts
@@ -49,7 +49,9 @@ describe( 'Transform from core table block to flexible table block', () => {
const wpVersion = await getWpVersion();
await createNewCoreTableBlock();
await openSidebar();
- const sidebarPanelTitle = wpVersion === '6-1' ? 'Settings' : 'Table settings';
+ const sidebarPanelTitle = [ '6-1', '6-2' ].includes( wpVersion )
+ ? 'Settings'
+ : 'Table settings';
await openSidebarPanelWithTitle( sidebarPanelTitle );
await clickToggleControlWithText( 'Header section' );
await clickToggleControlWithText( 'Footer section' );
@@ -61,7 +63,9 @@ describe( 'Transform from core table block to flexible table block', () => {
const wpVersion = await getWpVersion();
await createNewCoreTableBlock( { col: 6, row: 6 } );
await openSidebar();
- const sidebarPanelTitle = wpVersion === '6-1' ? 'Settings' : 'Table settings';
+ const sidebarPanelTitle = [ '6-1', '6-2' ].includes( wpVersion )
+ ? 'Settings'
+ : 'Table settings';
await openSidebarPanelWithTitle( sidebarPanelTitle );
await clickToggleControlWithText( 'Fixed width table cells' );
await transformBlockTo( 'Flexible Table' );
@@ -213,12 +217,11 @@ describe( 'Transform from flexible table block to core table block', () => {
await transformBlockTo( 'Table' );
// Figcaption has `.wp-element-caption` class in WordPress 6.1
- const snapShot =
- wpVersion === '6-1'
- ? `
+ const snapShot = [ '6-1', '6-2' ].includes( wpVersion )
+ ? `
`
- : `
+ : `
`;
@@ -239,12 +242,11 @@ describe( 'Transform from flexible table block to core table block', () => {
await transformBlockTo( 'Table' );
// Figcaption has `.wp-element-caption` class in WordPress 6.1
- const snapShot =
- wpVersion === '6-1'
- ? `
+ const snapShot = [ '6-1', '6-2' ].includes( wpVersion )
+ ? `
`
- : `
+ : `
`;