Add bogus phan workflow #287
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: QIT Self-Tests - Custom Tests | |
on: | |
# Every day at 11pm UTC (6pm ET) | |
schedule: | |
- cron: '0 23 * * *' | |
# Manually | |
workflow_dispatch: | |
# On push to trunk | |
push: | |
branches: | |
- trunk | |
jobs: | |
self_test_custom_test: | |
runs-on: ubuntu-20.04 | |
env: | |
NO_COLOR: 1 | |
QIT_DISABLE_ONBOARDING: yes | |
QIT_DISABLE_CLEANUP: 1 | |
QIT_SELF_TESTS: 1 | |
steps: | |
- name: Checkout code (Cross-platform) | |
uses: actions/checkout@v4 | |
- name: Create tmp directory on the workspace. | |
run: mkdir -p ${{ github.workspace }}/tmp | |
- name: Setup PHP (Cross-platform) | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '8.3' | |
extensions: imagick | |
ini-values: sys_temp_dir=${{ github.workspace }}/tmp | |
- name: Composer install | |
working-directory: _tests/custom_tests | |
run: composer install | |
- name: Composer install on Src | |
working-directory: src | |
run: composer install | |
- name: Fill in .env | |
working-directory: _tests/custom_tests | |
run: | | |
echo 'QIT_CUSTOM_TESTS_USER="noop"' >> .env | |
echo 'QIT_CUSTOM_TESTS_USER_QIT_TOKEN="noop"' >> .env | |
echo 'QIT_CUSTOM_TESTS_SECRET="${{ secrets.QIT_STAGING_SECRET }}"' >> .env | |
echo 'QIT_CUSTOM_TESTS_URL="https://stagingcompatibilitydashboard.wpcomstaging.com/"' >> .env | |
echo 'QIT_CUSTOM_TESTS_ENV="staging"' >> .env | |
- name: Run tests in parallel | |
working-directory: _tests/custom_tests | |
env: | |
QIT_NO_PULL: 1 | |
run: ./vendor/bin/phpunit | |
- name: Upload results | |
uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: qit-results | |
path: ${{ github.workspace }}/tmp/qit-results-* |