Just develop to master #192
This file contains hidden or 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: Smoke Tests | |
| permissions: | |
| contents: read | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| - develop | |
| workflow_dispatch: | |
| jobs: | |
| smoke: | |
| name: Composer, migrations, and smoke tests | |
| runs-on: ubuntu-latest | |
| services: | |
| mariadb: | |
| image: mariadb:10.11 | |
| env: | |
| MYSQL_ROOT_PASSWORD: root | |
| MYSQL_DATABASE: invoiceplane_test | |
| ports: | |
| - 3306:3306 | |
| options: >- | |
| --health-cmd="mysqladmin ping --silent" | |
| --health-interval=10s | |
| --health-timeout=5s | |
| --health-retries=5 | |
| env: | |
| APP_ENV: testing | |
| DB_CONNECTION: mysql | |
| DB_HOST: 127.0.0.1 | |
| DB_PORT: 3306 | |
| DB_DATABASE: invoiceplane_test | |
| DB_USERNAME: root | |
| DB_PASSWORD: root | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup PHP with Composer | |
| uses: ./.github/actions/setup-php-composer | |
| with: | |
| php-version: '8.4' | |
| php-extensions: 'mbstring, xml, ctype, json, fileinfo, pdo, pdo_mysql, bcmath' | |
| composer-flags: '--prefer-dist --no-interaction' | |
| - name: Prepare Laravel environment | |
| run: | | |
| cp .env.testing.example .env | |
| php artisan key:generate | |
| - name: Run migrations and seeders | |
| run: php artisan migrate --seed | |
| - name: Run smoke tests | |
| run: php artisan test --group=smoke |