-
Notifications
You must be signed in to change notification settings - Fork 7
36 lines (29 loc) · 876 Bytes
/
php-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: PHP 7.* Tests
on:
push: # Trigger on code pushes
branches:
- master
pull_request: # Trigger on pull requests
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
php: [7.0, 7.1, 7.2, 7.3, 7.4] # Define the PHP versions to test
steps:
# Step 1: Check out the repository
- name: Checkout Code
uses: actions/checkout@v3
# Step 2: Set up PHP
- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, xml, curl
coverage: none # Skip code coverage tools for faster testing
# Step 3: Install Dependencies
- name: Install Dependencies
run: composer install --no-progress --no-suggest
# Step 4: Run Tests
- name: Run PHPUnit Tests
run: vendor/bin/phpunit