Use PHP 7.4 for WooCommerce Blocks' `wp-env` Config (#51075)

This resolves a PHP 7.4 compatibility problem as well as updates the `wp-env` config for the Blocks tests to use 7.4 rather than the latest.
This commit is contained in:
Christopher Allford 2024-09-03 09:54:22 -07:00 committed by GitHub
parent c656fdc59b
commit caf9ec635e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 15 additions and 8 deletions

View File

@ -1,5 +1,6 @@
{ {
"core": null, "core": null,
"phpVersion": "7.4",
"plugins": [ "plugins": [
"https://github.com/WP-API/Basic-Auth/archive/master.zip", "https://github.com/WP-API/Basic-Auth/archive/master.zip",
"https://downloads.wordpress.org/plugin/wordpress-importer.0.8.zip", "https://downloads.wordpress.org/plugin/wordpress-importer.0.8.zip",

View File

@ -0,0 +1,4 @@
Significance: patch
Type: tweak
Comment: Just a change to the dev environment config.

View File

@ -304,14 +304,16 @@ class ProductCollection extends AbstractBlock {
$p->set_attribute( $p->set_attribute(
'data-wc-context', 'data-wc-context',
wp_json_encode( wp_json_encode(
array( array_merge(
...$current_context, $current_context,
// The message to be announced by the screen reader when the page is loading or loaded. array(
'accessibilityLoadingMessage' => __( 'Loading page, please wait.', 'woocommerce' ), // The message to be announced by the screen reader when the page is loading or loaded.
'accessibilityLoadedMessage' => __( 'Page Loaded.', 'woocommerce' ), 'accessibilityLoadingMessage' => __( 'Loading page, please wait.', 'woocommerce' ),
// We don't prefetch the links if user haven't clicked on pagination links yet. 'accessibilityLoadedMessage' => __( 'Page Loaded.', 'woocommerce' ),
// This way we avoid prefetching when the page loads. // We don't prefetch the links if user haven't clicked on pagination links yet.
'isPrefetchNextOrPreviousLink' => false, // This way we avoid prefetching when the page loads.
'isPrefetchNextOrPreviousLink' => false,
),
), ),
JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_QUOT | JSON_HEX_AMP JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_QUOT | JSON_HEX_AMP
) )