enable location map on all locations #1703
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: PHP Unit Tests | |
on: | |
push: | |
paths-ignore: | |
- '**.md' | |
- '**.txt' | |
pull_request: | |
branches: | |
- 'master' | |
env: | |
DB_DATABASE: wordpress_test | |
DB_USER: root | |
DB_PASSWORD: '' | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up MySQL | |
run: | | |
sudo /etc/init.d/mysql start | |
- uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '7.4' | |
extensions: uopz | |
- name: Validate composer.json and composer.lock | |
run: composer validate | |
- name: Cache Composer packages | |
id: composer-cache | |
uses: actions/cache@v3 | |
with: | |
path: vendor | |
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} | |
restore-keys: | | |
${{ runner.os }}-php- | |
- name: Install dependencies | |
run: | | |
bash bin/install-wp-tests.sh wordpress_test root root localhost latest | |
composer install --prefer-dist --no-progress | |
- name: Run test suite | |
run: | | |
composer dump-autoload -o | |
curl -ksSfL -o ~/phpunit-9.phar https://phar.phpunit.de/phpunit-9.phar | |
php ~/phpunit-9.phar --version | |
php ~/phpunit-9.phar | |
- name: Upload coverage reports to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
files: ./build/logs/clover.xml |