fix (icon block): deprecation error, return false for isEligible if n… #3760
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: Unit Tests / PHP (v5.6.39) | |
on: | |
push: | |
branches: [ master, develop ] | |
pull_request: | |
branches: [ master, develop ] | |
jobs: | |
build: | |
# Use Ubuntu 20.04. | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
wp-versions: ['6.3.5'] | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/checkout@v2 # Checkout the Stackable Premium repo. | |
with: | |
repository: 'bfintal/Stackable-Premium' | |
ref: 'v3' | |
path: 'pro__premium_only' | |
token: '${{ secrets.ACCESS_KEY }}' | |
# Change the PHP version to v5.6.39 | |
- name: Setup PHP v5.6.39 | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '5.6.39' | |
# Check the current PHP version installed | |
- name: Check PHP version | |
run: php -v | |
- name: Install dependencies | |
run: | | |
composer require phpunit/phpunit:5.6.8 --dev | |
composer require wp-phpunit/wp-phpunit:${{ matrix.wp-versions }} --dev | |
composer require roots/wordpress:${{ matrix.wp-versions }} --dev | |
composer install --prefer-dist --no-progress | |
- name: Setup Node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 14.x | |
- name: Build Stackable Free Plugin | |
run: | | |
npm ci | |
npm run build --if-present | |
- name: Setup MySQL | |
uses: mirromutth/[email protected] | |
with: | |
mysql database: 'stackable' # Optional, default value is "test". The specified database which will be create | |
mysql root password: 'root' # Required if "mysql user" is empty, default is empty. The root superuser password | |
mysql version: '5.6' | |
mysql user: 'root' # Required if "mysql root password" is empty, default is empty. The superuser for the specified database. Can use secrets, too | |
mysql password: 'root' # Required if "mysql user" exists. The password for the "mysql user" | |
# Wait for MySQL server to initialize. | |
- name: Wait for MySQL | |
run: | | |
while ! mysqladmin ping --host=127.0.0.1 --password=root --silent; do | |
sleep 1 | |
done | |
# Run all tests. | |
- name: Run test suite | |
env: | |
MYSQL_GITHUB_ACTION: true | |
MYSQL_DATABASE: stackable | |
MYSQL_USER: root | |
MYSQL_PASSWORD: root | |
MYSQL_ROOT_PASSWORD: root | |
MYSQL_PORT: 3306 | |
run: composer run-script test |