Merge pull request #16 from intaro/types-fix #8
Workflow file for this run
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: CI | |
on: [push] | |
jobs: | |
build-ext: | |
name: "PHPUnit (PHP ${{ matrix.version.php }}, hstore-ext: ${{ matrix.hstore_ext }})" | |
runs-on: ubuntu-latest | |
strategy: | |
# fail-fast: true | |
matrix: | |
version: | |
- { php: 8.0, composer: 2.x, phpunit: 8.5 } | |
- { php: 8.1, composer: 2.x, phpunit: 8.5 } | |
- { php: 8.2, composer: 2.x, phpunit: 8.5 } | |
- { php: 8.3, composer: 2.x, phpunit: 9.5 } | |
hstore_ext: | |
- no | |
- yes | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: PHP ${{ matrix.version.php }} install | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.version.php }} | |
- name: Composer validate | |
uses: php-actions/composer@v6 | |
with: | |
version: ${{ matrix.version.composer }} | |
php_version: ${{ matrix.version.php }} | |
command: validate | |
- name: Composer install | |
uses: php-actions/composer@v6 | |
with: | |
version: ${{ matrix.version.composer }} | |
php_version: ${{ matrix.version.php }} | |
args: --prefer-source | |
- name: Build extension | |
run: "cd ext/hstore && phpize && ./configure --enable-hstore && make && sudo make install" | |
if: matrix.hstore_ext == 'yes' | |
env: | |
PHP_VERSION: ${{ matrix.version.php }} | |
- name: enable hstore ext | |
if: matrix.hstore_ext == 'yes' | |
run: echo 'extension = hstore.so' | sudo tee -a "$(php -i | grep 'additional .ini files' | awk '{print $9}')"/99-hstore.ini | |
- name: php -m | |
run: php -m | |
- name: php -i | |
run: php -i | grep ini | |
- name: PHPUnit | |
run: ./vendor/bin/phpunit | |
- name: Benchmark | |
run: php tests/Benchmark.php |