Github Actions are defined in a YAML file named <workflow name>.yml
and are listed in the .github/workflows
folder at the root of your project.
You can store as many workflows as your project requires.
Created
February 12, 2025 07:10
-
-
Save abenevaut/c86ab8d559b92f2d93b028a0e6e832d9 to your computer and use it in GitHub Desktop.
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: test-my-laravel-project | |
on: | |
pull_request: | |
branches: [ master ] | |
env: | |
php_version: 8.3 | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
concurrency: | |
group: test-my-laravel-project-${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
steps: | |
- name: Checkout project | |
uses: actions/checkout@v3 | |
- name: Initialize PHP ${{ env.php_version }} | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ env.php_version }} | |
coverage: pcov | |
- name: Composer install | |
run: | | |
composer validate --strict | |
composer install --optimize-autoloader --no-interaction --prefer-dist | |
- name: Test | |
run: php artisan test |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment