-
Notifications
You must be signed in to change notification settings - Fork 2
130 lines (105 loc) · 4.18 KB
/
Copy pathcontinuous-integration.yml
File metadata and controls
130 lines (105 loc) · 4.18 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
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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
# https://help.github.com/en/categories/automating-your-workflow-with-github-actions
# file-version: 1.0
name: "Continuous Integration"
on:
- pull_request
- push
permissions:
contents: read
security-events: read
issues: read
pull-requests: read
checks: read
concurrency:
group: "${{ github.event_name }}-${{ github.workflow }}-${{ github.head_ref || github.run_id }}-${{ github.ref }}"
cancel-in-progress: true
jobs:
validate-all:
name: "Validate Project"
uses: "mimmi20/ci/.github/workflows/validate-all.yml@8.3"
with:
skip-validate-yaml: false
skip-validate-md: false
validate-php:
name: "Validate PHP"
uses: "mimmi20/ci/.github/workflows/validate-php.yml@8.3"
with:
extensions: "ctype, curl, dom, fileinfo, iconv, intl, mbstring, simplexml, tokenizer, xml, xmlwriter"
ini-values: "opcache.enable=1, opcache.fast_shutdown=0, zend.assertions=1, assert.exception=On, intl.default_locale=de, intl.use_exceptions=1, zend.exception_ignore_args=0"
composer-options: "--optimize-autoloader --prefer-dist --prefer-stable -v"
skip-validate-composer: true
skip-phplint: false
skip-check-composer: false
skip-ec-checker: false
dependency-analyser-options: ""
install:
name: "Install Project"
needs:
- "validate-all"
- "validate-php"
uses: "mimmi20/ci/.github/workflows/install-php.yml@8.3"
with:
extensions: "ctype, curl, dom, fileinfo, iconv, mbstring, intl, simplexml, tokenizer, xml, xmlwriter"
ini-values: "opcache.enable=1, opcache.fast_shutdown=0, zend.assertions=1, assert.exception=On, intl.default_locale=de, intl.use_exceptions=1, zend.exception_ignore_args=0"
composer-options: "--optimize-autoloader --prefer-dist --prefer-stable -v"
skip-librabbitmq-install: true
skip-libgif-install: true
analytics:
name: "Project Analysis"
permissions:
security-events: write
id-token: write
contents: read
issues: read
pull-requests: read
checks: read
needs: "install"
uses: "mimmi20/ci/.github/workflows/analytics-php.yml@8.3"
with:
extensions: "ctype, curl, dom, fileinfo, iconv, intl, mbstring, simplexml, tokenizer, xml, xmlwriter"
ini-values: "opcache.enable=1, opcache.fast_shutdown=0, zend.assertions=1, assert.exception=On, intl.default_locale=de, intl.use_exceptions=1, zend.exception_ignore_args=0"
composer-options: "--optimize-autoloader --prefer-dist --prefer-stable -v"
skip-php-cs-fixer: false
skip-phpcs: false
skip-phpstan: false
skip-rector: false
use-code-scanning: true
phpcs-options: ""
tests:
name: "UnitTests"
needs: "analytics"
uses: "mimmi20/ci/.github/workflows/test-php.yml@8.3"
with:
extensions: "ctype, dom, fileinfo, intl, simplexml, tokenizer, xml, xmlwriter"
ini-values: "opcache.enable=1, opcache.fast_shutdown=0, zend.assertions=1, assert.exception=On, intl.default_locale=de, intl.use_exceptions=1, zend.exception_ignore_args=0"
coverage: "xdebug"
composer-options: "--optimize-autoloader --prefer-dist --prefer-stable -v"
test-name: ""
min-msi: 100
min-covered-msi: 100
skip-librabbitmq-install: true
skip-libgif-install: true
upload-codecov: true
upload-codeclimate: true
upload-coveralls: true
upload-flag: ""
use-phpstan: true
secrets:
ENV_CODECLIMATE_API_KEY: ${{ secrets.CODECLIMATE_API_KEY }}
ENV_CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
ENV_STRYKER_DASHBOARD_API_KEY: ${{ secrets.STRYKER_DASHBOARD_API_KEY }}
# This is a meta job to avoid to have to constantly change the protection rules
# whenever we touch the matrix.
tests-status:
name: "CI Status"
runs-on: "ubuntu-latest"
if: always()
needs:
- "tests"
steps:
- name: Failing run
if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'skipped') || contains(needs.*.result, 'cancelled') }}
run: exit 1
- name: Successful run
if: ${{ !(contains(needs.*.result, 'failure')) && !(contains(needs.*.result, 'skipped')) && !(contains(needs.*.result, 'cancelled')) }}
run: exit 0