Skip to content

Commit

Permalink
Test: Run database upgrades between performance test steps.
Browse files Browse the repository at this point in the history
Prevents pending upgrades from blocking tests when checking out previous builds.

Props mukesh27.
See #59647.

git-svn-id: https://develop.svn.wordpress.org/trunk@57143 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
swissspidy committed Nov 29, 2023
1 parent 96339bd commit fdec267
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,13 @@ jobs:
# - Check out target commit (target branch or previous commit).
# - Install npm dependencies.
# - Build WordPress.
# - Run any database upgrades.
# - Run performance tests (previous/target commit).
# - Print target performance tests results.
# - Reset to original commit.
# - Install npm dependencies.
# - Set the environment to the baseline version.
# - Run any database upgrades.
# - Run baseline performance tests.
# - Print baseline performance tests results.
# - Compare results with base.
Expand Down Expand Up @@ -194,6 +196,9 @@ jobs:
- name: Build WordPress
run: npm run build

- name: Run any database upgrades
run: npm run env:cli -- core update-db --path=/var/www/${{ env.LOCAL_DIR }}

- name: Run target performance tests (base/previous commit)
env:
TEST_RESULTS_PREFIX: before
Expand All @@ -215,6 +220,9 @@ jobs:
npm run env:cli -- core update --version=${{ env.BASE_TAG }} --force --path=/var/www/${{ env.LOCAL_DIR }}
npm run env:cli -- core version --path=/var/www/${{ env.LOCAL_DIR }}
- name: Run any database upgrades
run: npm run env:cli -- core update-db --path=/var/www/${{ env.LOCAL_DIR }}

- name: Run baseline performance tests
env:
TEST_RESULTS_PREFIX: base
Expand Down

0 comments on commit fdec267

Please sign in to comment.