Fix test workflow matrix for databases
This commit is contained in:
parent
db74b0024d
commit
0b521c011f
|
@ -46,8 +46,6 @@ jobs:
|
||||||
~/.php_cs.cache
|
~/.php_cs.cache
|
||||||
${{ steps.composer-cache.outputs.dir }}
|
${{ steps.composer-cache.outputs.dir }}
|
||||||
key: ${{ runner.os }}-cache-${{ matrix.php }}-${{ hashFiles('**.composer.lock') }}
|
key: ${{ runner.os }}-cache-${{ matrix.php }}-${{ hashFiles('**.composer.lock') }}
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-cache-${{ matrix.php }}-
|
|
||||||
- name: setup
|
- name: setup
|
||||||
uses: shivammathur/setup-php@v2
|
uses: shivammathur/setup-php@v2
|
||||||
with:
|
with:
|
||||||
|
@ -63,20 +61,20 @@ jobs:
|
||||||
run: vendor/bin/php-cs-fixer fix --dry-run --diff --diff-format=udiff --config .php_cs.dist
|
run: vendor/bin/php-cs-fixer fix --dry-run --diff --diff-format=udiff --config .php_cs.dist
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
- name: execute unit tests
|
- name: execute unit tests
|
||||||
run: vendor/bin/phpunit --bootstrap bootstrap/app.php tests/Unit
|
run: vendor/bin/phpunit --bootstrap vendor/autoload.php tests/Unit
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
env:
|
env:
|
||||||
DB_CONNECTION: testing
|
DB_CONNECTION: testing
|
||||||
TESTING_DB_HOST: UNIT_NO_DB
|
TESTING_DB_HOST: UNIT_NO_DB
|
||||||
- name: execute integration tests (mysql)
|
- name: execute integration tests (mysql)
|
||||||
run: vendor/bin/phpunit tests/Integration
|
run: vendor/bin/phpunit tests/Integration
|
||||||
if: "${{ matrix.database }} == 'mysql'"
|
if: ${{ matrix.database == 'mysql' }}
|
||||||
env:
|
env:
|
||||||
TESTING_DB_PORT: ${{ job.services.mysql.ports[3306] }}
|
TESTING_DB_PORT: ${{ job.services.mysql.ports[3306] }}
|
||||||
TESTING_DB_USERNAME: root
|
TESTING_DB_USERNAME: root
|
||||||
- name: execute integration tests (mariadb)
|
- name: execute integration tests (mariadb)
|
||||||
run: vendor/bin/phpunit tests/Integration
|
run: vendor/bin/phpunit tests/Integration
|
||||||
if: "${{ matrix.database }} == 'mariadb'"
|
if: ${{ matrix.database == 'mariadb' }}
|
||||||
env:
|
env:
|
||||||
TESTING_DB_PORT: ${{ job.services.mariadb.ports[3306] }}
|
TESTING_DB_PORT: ${{ job.services.mariadb.ports[3306] }}
|
||||||
TESTING_DB_USERNAME: root
|
TESTING_DB_USERNAME: root
|
||||||
|
|
Loading…
Reference in New Issue