Skip to content

Commit

Permalink
Test Lower and Upper PHP Versions
Browse files Browse the repository at this point in the history
PHP 7.1 is the lowest, PHP 7.4 is the higher. By testing both we should be eco-friendly and covering all what is new in PHP 7.4 but also all what is legacy in the lower bound.
  • Loading branch information
DiegoPino authored Aug 13, 2021
1 parent ad4826e commit eec39b0
Showing 1 changed file with 17 additions and 11 deletions.
28 changes: 17 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,16 @@ on:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:

- uses: actions/checkout@v2
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest]
php-versions: ['7.1', '7.4']

name: frictionlessdata/datapackage-php PHP ${{ matrix.php-versions }} test on ${{ matrix.operating-system }}

steps:
- uses: actions/checkout@v2

- name: Cache Composer dependencies
uses: actions/cache@v2
Expand All @@ -19,31 +25,31 @@ jobs:

- uses: php-actions/composer@v6
with:
php_version: 7.1
php_version: ${{ matrix.php-versions }}
php_extensions: zip
version: 2

- name: Validate composer.json & composer.lock
- name: Validate composer.json & composer.lock for PHP ${{ matrix.php-versions }}
uses: php-actions/composer@v6
with:
php_version: 7.1
php_version: ${{ matrix.php-versions }}
php_extensions: zip
version: 2
command: validate --strict

- name: Run Code Style Check
- name: Run Code Style Check for PHP ${{ matrix.php-versions }}
uses: php-actions/composer@v6
with:
php_version: 7.1
php_version: ${{ matrix.php-versions }}
php_extensions: zip
version: 2
dev: yes
command: style-check

- name: Run Tests
- name: Run Tests for PHP ${{ matrix.php-versions }}
uses: php-actions/composer@v6
with:
php_version: 7.1
php_version: ${{ matrix.php-versions }}
php_extensions: zip
dev: yes
command: test
Expand Down

0 comments on commit eec39b0

Please sign in to comment.