Skip to content

Bump webpack-dev-server from 3.11.2 to 5.2.1 #17

Bump webpack-dev-server from 3.11.2 to 5.2.1

Bump webpack-dev-server from 3.11.2 to 5.2.1 #17

name: End-to-end Tests
on:
# The end to end test suite was introduced in WordPress 5.3.
push:
branches:
- master
- trunk
- '5.[3-9]'
- '[6-9].[0-9]'
tags:
- '5.[3-9]*'
- '[6-9].[0-9]*'
pull_request:
branches:
- master
- trunk
- '5.[3-9]'
- '[6-9].[0-9]'
workflow_dispatch:
# Cancels all previous workflow runs for pull requests that have not completed.
concurrency:
# The concurrency group contains the workflow name and the branch name for pull requests
# or the commit hash for any other events.
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
cancel-in-progress: true
env:
LOCAL_DIR: build
jobs:
# Runs the end-to-end test suite.
#
# Performs the following steps:
# - Set environment variables.
# - Checks out the repository.
# - Logs debug information about the runner container.
# - Installs NodeJS 14.
# _ Installs NPM dependencies using install-changed to hash the `package.json` file.
# - Builds WordPress to run from the `build` directory.
# - Starts the WordPress Docker container.
# - Logs general debug information.
# - Logs the running Docker containers.
# - Logs Docker debug information (about both the Docker installation within the runner and the WordPress container).
# - Install WordPress within the Docker container.
# - Run the E2E tests.
# - Ensures version-controlled files are not modified or deleted.
e2e-tests:
name: E2E Tests
runs-on: ubuntu-latest
if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
steps:
- name: Configure environment variables
run: |
echo "PHP_FPM_UID=$(id -u)" >> $GITHUB_ENV
echo "PHP_FPM_GID=$(id -g)" >> $GITHUB_ENV
- name: Checkout repository
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
- name: Log debug information
run: |
npm --version
node --version
curl --version
git --version
svn --version
php --version
php -i
locale -a
- name: Install NodeJS
uses: actions/setup-node@38d90ce44d5275ad62cc48384b3d8a58c500bb5f # v2.2.2
with:
node-version: 14
cache: npm
- name: Install Dependencies
run: npm ci
- name: Build WordPress
run: npm run build
- name: Start Docker environment
run: |
npm run env:start
- name: General debug information
run: |
npm --version
node --version
curl --version
git --version
svn --version
- name: Log running Docker containers
run: docker ps -a
- name: Docker debug information
run: |
docker -v
docker-compose -v
docker-compose run --rm mysql mysql --version
docker-compose run --rm php php --version
docker-compose run --rm php php -m
docker-compose run --rm php php -i
docker-compose run --rm php locale -a
- name: Install WordPress
run: npm run env:install
- name: Run E2E tests
run: npm run test:e2e
- name: Ensure version-controlled files are not modified or deleted
run: git diff --exit-code
# Post workflow related status updates to Slack.
#
# When a job in this workflow fails, a message is posted to #core.
#
# This job should always require all other jobs in this workflow to complete before running.
slack-notifications:
name: Slack Notifications
runs-on: ubuntu-latest
needs: [ e2e-tests ]
if: ${{ failure() && github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' }}
steps:
- name: Post failure notification to Slack
uses: slackapi/slack-github-action@d5d276d7ae0f38f29322b80da9baf985cc80f8b1 # v1.15.0
with:
payload: "{\"workflow_name\":\"${{ github.workflow }}\",\"run_url\":\"https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}\"}"
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_GHA_WEBHOOK_URL }}