-
Notifications
You must be signed in to change notification settings - Fork 24
44 lines (40 loc) · 1.02 KB
/
continuous-integration.yml
File metadata and controls
44 lines (40 loc) · 1.02 KB
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
37
38
39
40
41
42
43
44
name: Continuous Integration
on:
- pull_request
- push
jobs:
testing:
name: Tests
runs-on: ubuntu-24.04
strategy:
matrix:
php:
- "8.1"
- "8.2"
- "8.3"
- "8.4"
mongo:
- "7.0"
- "8.0"
services:
mongodb:
image: mongo:${{ matrix.mongo }}
ports:
- "27017:27017"
steps:
- name: Checkout
uses: actions/checkout@v3
- name: PHP setup
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mongodb-mongodb/mongo-php-driver@1.20.1
- name: Composer
uses: ramsey/composer-install@v2
- name: Running tests
run: vendor/bin/phpunit -c phpunit.xml.dist --coverage-clover=./coverage/clover.xml
- name: Report coverage
uses: codacy/codacy-coverage-reporter-action@v1
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: ./coverage/clover.xml