-
Notifications
You must be signed in to change notification settings - Fork 9
98 lines (80 loc) · 2.93 KB
/
build.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
89
90
91
92
93
94
95
96
97
98
name: Build
on:
push:
branches-ignore:
- "dependabot/**"
paths-ignore:
- "*.md"
pull_request:
paths-ignore:
- "*.md"
release:
types: [created]
schedule:
- cron: "0 1 * * 6" # Run at 1am every Saturday
workflow_dispatch: ~
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
tests:
runs-on: ubuntu-latest
name: "Sylius ${{ matrix.sylius }}, PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, MySQL ${{ matrix.mysql }}"
strategy:
fail-fast: false
matrix:
php: ["8.0"]
symfony: ["^5.4"]
sylius: ["~1.10.0", "~1.11.0", "~1.12.0"]
mysql: ["8.0"]
node: ["18.x"]
include:
- php: "8.0"
symfony: "^6.0"
sylius: "~1.12.0"
mysql: "8.0"
node: "18.x"
env:
APP_ENV: test
DATABASE_URL: "mysql://root:[email protected]/sylius?serverVersion=${{ matrix.mysql }}"
SAFERPAY_TEST_API_URL: "http://localhost:4000/"
steps:
- uses: actions/checkout@v3
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "${{ matrix.php }}"
extensions: intl
tools: flex,symfony
coverage: none
- name: Build test application
uses: SyliusLabs/[email protected]
with:
symfony-version: "${{ matrix.symfony }}"
sylius-version: "${{ matrix.sylius }}"
mysql-version: "${{ matrix.mysql }}"
node-version: "${{ matrix.node }}"
plugin-build: "yes"
- name: Run ECS
run: vendor/bin/ecs check
- name: Run PHPStan
run: vendor/bin/phpstan analyse
- name: Run Psalm
run: vendor/bin/psalm
- name: Run PHPSpec
run: vendor/bin/phpspec run --ansi -f progress --no-interaction
- name: Run PHPUnit
run: vendor/bin/phpunit --colors=always
- name: Run Mockoon
run: |
npm install -g @mockoon/cli
npx mockoon-cli start --data tests/mockoon.json &
- name: Run Behat
run: vendor/bin/behat --format=progress --colors --strict -vvv --no-interaction --tags="~@todo"
- name: Upload Behat logs
uses: actions/upload-artifact@v2
if: failure()
with:
name: Behat logs
path: etc/build/
if-no-files-found: ignore