Skip to content

Commit

Permalink
Update automation.yml
Browse files Browse the repository at this point in the history
Signed-off-by: Nathanael Esayeas <nathanael.esayeas@protonmail.com>
  • Loading branch information
ghostwriter committed Jun 29, 2023
1 parent 41ff30d commit 3bf14b2
Showing 1 changed file with 8 additions and 46 deletions.
54 changes: 8 additions & 46 deletions .github/workflows/automation.yml
Expand Up @@ -37,19 +37,6 @@ jobs:
needs: [matrix]
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental }}

# Docs: https://docs.github.com/en/actions/using-containerized-services
# services:
# mysql:
# image: mysql:latest
# env:
# MYSQL_ALLOW_EMPTY_PASSWORD: false
# MYSQL_ROOT_PASSWORD: 'toor'
# MYSQL_DATABASE: 'testdb'
# ports:
# - 3306/tcp
# options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3

strategy:
fail-fast: false
matrix: ${{ fromJSON(needs.matrix.outputs.matrix) }}
Expand All @@ -60,43 +47,18 @@ jobs:
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
coverage: pcov
ini-values: assert.exception=1, zend.assertions=1, error_reporting=-1, log_errors_max_len=0, display_errors=On
php-version: ${{ matrix.php }}
coverage: xdebug
tools: psalm, phpstan, cs2pr, phpcs, phpunit


# Local MySQL service in GitHub hosted environments is disabled by default.
# If you are using it instead of service containers, make sure you start it.
# - name: Start mysql service
# run: sudo systemctl start mysql.service

# - name: Run Migration
# run: |
# php bin/console migrations:migrate || echo "No migrations found or migration failed"
# env:
# DATABASE_URL: mysql://root:toor@127.0.0.1:${{ job.services.mysql.ports['3306'] }}/testdb

# - name: Run phpcs
# run: phpcs -q --report=checkstyle src | cs2pr

# - name: Run Psalm
# run: psalm --output-format=github
# if: true

# - name: Run PHPStan
# run: phpstan analyse src

# - name: Run PHPUnit
# run: phpunit

- name: Setup problem matchers for PHP
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"

- name: Setup Problem Matchers
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Setup problem matchers
run: |
echo "::add-matcher::${{ runner.tool_cache }}/php.json"
echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Install ${{ matrix.dependencies }} dependencies
uses: "ramsey/composer-install@v2"
uses: ramsey/composer-install@v2
with:
dependency-versions: "${{ matrix.dependencies }}"

Expand Down Expand Up @@ -135,7 +97,7 @@ jobs:
php-version: '8.2'

- name: Install dependencies
run: composer self-update && composer install && composer dump-autoload
uses: ramsey/composer-install@v2

- name: Run tests and collect coverage
run: composer phpunit
Expand Down

0 comments on commit 3bf14b2

Please sign in to comment.