Skip to content

Merge downstream Framework patch version #7541

Merge downstream Framework patch version

Merge downstream Framework patch version #7541

Workflow file for this run

# This workflow is especially helpful for pull requests to quickly see if the other tests will definitely fail
name: 🔥 Smoke Tests
on:
pull_request:
jobs:
run-smoke-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Install Composer Dependencies
run: composer install --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
- name: Run smoke tests
run: vendor/bin/pest --stop-on-failure --log-junit report.xml
- name: Ping statistics server with test results
run: |
curl https://raw.githubusercontent.com/hydephp/develop/6e9d17f31879f4ccda13a3fec4029c9663bccec0/monorepo/scripts/ping-openanalytics-testrunner.php -o ping.php
php ping.php "Monorepo Smoke Tests" ${{ secrets.OPENANALYTICS_TOKEN }} ${{ github.ref_name }}
test-coverage:
runs-on: ubuntu-latest
steps:
- uses: shivammathur/setup-php@v2
with:
php-version: "8.1"
coverage: xdebug
extensions: fileinfo
- uses: actions/checkout@v3
- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Install Composer Dependencies
run: composer install --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
- name: Set environment to testing
run: echo "ENV=testing" > .env
- name: Execute tests (Unit and Feature tests) via PHPUnit with coverage
run: vendor/bin/pest --coverage --coverage-clover clover.xml --log-junit report.xml
- name: "Publish coverage report to Codecov"
uses: codecov/codecov-action@v3
with:
functionalities: network
- name: Ping statistics server with test results
run: |
curl https://raw.githubusercontent.com/hydephp/develop/6e9d17f31879f4ccda13a3fec4029c9663bccec0/monorepo/scripts/ping-openanalytics-testrunner.php -o ping.php
php ping.php "Monorepo Smoke Tests - Coverage" ${{ secrets.OPENANALYTICS_TOKEN }} ${{ github.ref_name }}