fixed an updates in SQS #19
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: tests | |
on: [push] | |
jobs: | |
test: | |
name: PHPUnit | |
runs-on: ubuntu-latest | |
env: | |
DB_DATABASE: mail_queue_test | |
DB_USER: root | |
DB_PASSWORD: root | |
steps: | |
- name: checkout repo | |
uses: actions/checkout@v3 | |
- name: setup enviroment | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: '8.1' | |
- name: Install dependencies | |
run: composer install | |
- name: Set up MySQL | |
run: | | |
sudo /etc/init.d/mysql start | |
mysql -e 'CREATE DATABASE ${{ env.DB_DATABASE }};' -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }} | |
- name: Run unit tests | |
run: ./vendor/bin/phpunit --coverage-clover ./tests/_output/coverage.xml | |
- name: Upload coverage reports to Codacy | |
uses: codacy/codacy-coverage-reporter-action@v1 | |
with: | |
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} | |
coverage-reports: ./tests/_output/coverage.xml |