-
Notifications
You must be signed in to change notification settings - Fork 0
88 lines (72 loc) · 2.77 KB
/
php-checks.yaml
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
name: PHP - Checks
on:
push:
branches:
- master
- main
pull_request:
schedule:
- cron: '0 3 * * *'
jobs:
checks:
runs-on: ubuntu-latest
name: PHP 8.1 - checks
steps:
# Setup
- uses: actions/checkout@v2
- name: '[PHP] Setup'
uses: shivammathur/setup-php@v2
with:
php-version: 8.1
extensions: mbstring, intl
coverage: xdebug
# Prepare application
- name: '[INIT] Check composer.json'
run: composer validate --no-check-all --no-check-publish --no-check-lock
- name: '[INIT] Install dependencies'
run: composer install
# Check application
- name: '[CHECK] analyze'
run: composer analyze
- name: '[CHECK] phpstan'
run: composer phpstan
- name: '[CHECK] Unit tests'
run: composer tests-ci
- name: Submit coverage to Coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_PARALLEL: true
COVERALLS_FLAG_NAME: ${{ github.job }}-PHP-8.1
run: |
composer global require php-coveralls/php-coveralls
~/.composer/vendor/bin/php-coveralls --coverage_clover=./code-coverage/clover.xml --json_path=./code-coverage/coveralls-upload.json -v
- name: Notify Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true
selenium-checks:
runs-on: ubuntu-latest
name: PHP 8.1 - selenium checks
steps:
# Setup
- uses: actions/checkout@v2
- name: '[PHP] Setup'
uses: shivammathur/setup-php@v2
with:
php-version: 8.1
extensions: mbstring, intl
# Prepare application
- name: '[INIT] Check composer.json'
working-directory: ./selenium-tests
run: composer validate --no-check-all --no-check-publish --no-check-lock
- name: '[INIT] Install dependencies'
working-directory: ./selenium-tests
run: composer install
# Check selenium
- name: '[CHECK] codestyle'
working-directory: ./selenium-tests
run: composer analyze
- name: '[CHECK] phpstan'
working-directory: ./selenium-tests
run: composer phpstan