Skip to content

Composer Dependency Analyser: update to analyse ext-* (#960) #1073

Composer Dependency Analyser: update to analyse ext-* (#960)

Composer Dependency Analyser: update to analyse ext-* (#960) #1073

name: Integration Tests
on:
pull_request:
paths:
- 'src/**'
- 'tests/**'
- '.github/workflows/integration-tests.yml'
- 'composer.json'
push:
branches: ['7.x']
paths:
- 'src/**'
- 'tests/**'
- '.github/workflows/integration-tests.yml'
- 'composer.json'
workflow_dispatch:
jobs:
integration-tests:
name: Integration Tests
runs-on: ubuntu-latest
env:
php-version: '8.3'
extensions: ctype, dom, grpc, json, mbstring, openssl, xml, zip, zlib
key: cache-integration-7x-${{ matrix.php }}-v1
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup cache environment
id: extcache
uses: shivammathur/cache-extensions@v1
with:
php-version: ${{ env.php-version }}
extensions: ${{ env.extensions }}
key: ${{ env.key }}
- name: Cache extensions
uses: actions/[email protected]
with:
path: ${{ steps.extcache.outputs.dir }}
key: ${{ steps.extcache.outputs.key }}
restore-keys: ${{ steps.extcache.outputs.key }}
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ env.php-version }}
extensions: ${{ env.extensions }}
tools: composer, pecl
coverage: xdebug
- name: Setup problem matchers for PHP
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
- uses: "ramsey/composer-install@v3"
- name: Setup Problem Matchers for PHPUnit
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Run Integration Tests
env:
GOOGLE_APPLICATION_CREDENTIALS: ${{secrets.GOOGLE_APPLICATION_CREDENTIALS}}
TEST_FIREBASE_APP_ID: ${{secrets.TEST_FIREBASE_APP_ID}}
TEST_FIREBASE_RTDB_URI: ${{secrets.TEST_FIREBASE_RTDB_URI}}
TEST_FIREBASE_TENANT_ID: ${{secrets.TEST_FIREBASE_TENANT_ID}}
TEST_REGISTRATION_TOKENS: ${{secrets.TEST_REGISTRATION_TOKENS}}
XDEBUG_MODE: coverage
run: vendor/bin/phpunit --testsuite=integration --coverage-clover=coverage.xml --log-junit=test-report.xml --testdox
- name: Upload code coverage
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: integration
if: github.repository_owner == 'kreait'