diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 7d257b5..9446404 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -10,6 +10,25 @@ permissions: contents: read jobs: + test: + runs-on: ubuntu-latest + + env: + DB_DATABASE: test_db + DB_USER: root + DB_PASSWORD: root + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Start MySQL + run: | + sudo /etc/init.d/mysql start + mysql -e "CREATE DATABASE IF NOT EXISTS $DB_DATABASE;" -u$DB_USER -p$DB_PASSWORD + # Add more steps for testing and other tasks + - name: Run Tests + run: composer run-script test build: runs-on: ubuntu-latest @@ -35,5 +54,5 @@ jobs: # Add a test script to composer.json, for instance: "test": "vendor/bin/phpunit" # Docs: https://getcomposer.org/doc/articles/scripts.md - # - name: Run test suite - # run: composer run-script test + - name: Run test suite + run: composer run-script test