Skip to content

Commit

Permalink
Internal: Upgrade wp-env and revert workarounds (elementor#25229)
Browse files Browse the repository at this point in the history
Reverts elementor#25223 and upgrades `wp-env` to 9.4.0 which uses MariaDB LTS
instead of latest WordPress/gutenberg#59237

---------

Co-authored-by: ElementorBot <48412871+elementorbot@users.noreply.github.com>
  • Loading branch information
2 people authored and Nevoss committed Feb 22, 2024
1 parent 2b6f124 commit fe9f00c
Show file tree
Hide file tree
Showing 8 changed files with 114 additions and 1,472 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/lighthouse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ jobs:
key: npm-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
- name: Install dependencies
if: github.event.pull_request.title == null || steps.changelog_diff_files.outputs.diff
run: |
npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
run: npm ci
- name: Build
if: github.event.pull_request.title == null || steps.changelog_diff_files.outputs.diff
run: npx grunt build
Expand Down Expand Up @@ -96,9 +94,7 @@ jobs:
key: ${{ github.sha }}
- name: Install node modules
if: matrix.wpCoreVersion != 'master'
run: |
npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
run: npm ci
- name: Run wp-env
if: matrix.wpCoreVersion != 'master'
run: |
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,7 @@ jobs:
WP_CORE_VERSION: 'latest'
run: node ./.github/scripts/build-wp-env.js
- name: Install dependencies
run: |
npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
run: npm ci
- name: Install WordPress environment
run: |
npm run start-local-server
Expand Down
6 changes: 1 addition & 5 deletions .github/workflows/plugin-upgrade-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@ jobs:
path: ~/.npm
key: npm-${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
- name: Install dependencies
run: |
npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
run: npm ci
- name: Build
run: npx grunt build
- name: Cache node modules
Expand Down Expand Up @@ -76,9 +74,7 @@ jobs:
- name: Install dependencies
run: |
npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
cd ./tests/playwright/upgrade-test && npm ci
sed -i -e "s/image: 'mariadb'/image: 'mariadb:11.2.2-jammy'/g" node_modules/@wordpress/env/lib/build-docker-compose-config.js
- name: Run upgrade test
run: cd ./tests/playwright/upgrade-test && npm run test:upgrade:elementor
env:
Expand Down
55 changes: 39 additions & 16 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"@testing-library/react": "^14.1.2",
"@wordpress/babel-plugin-import-jsx-pragma": "~3.2.0",
"@wordpress/babel-preset-default": "^3.0.2",
"@wordpress/env": "^8.11.0",
"@wordpress/env": "^9.4.0",
"@wordpress/eslint-plugin": "^17.2.0",
"allure-playwright": "^2.10.0",
"autoprefixer": "~10.4.12",
Expand Down
2 changes: 1 addition & 1 deletion tests/playwright/upgrade-test/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class UpgradeElementor {
}

runServer() {
this.cmd( 'npm run wp-env start' );
this.cmd( 'npx wp-env start' );
}

installPluginFromWP() {
Expand Down
Loading

0 comments on commit fe9f00c

Please sign in to comment.