-
Notifications
You must be signed in to change notification settings - Fork 12
120 lines (105 loc) · 4.01 KB
/
codeception.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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
name: "Codeception Tests"
on:
schedule:
- cron: '0 3 * * 1,3,5'
pull_request:
branches:
- "[0-9]+.[0-9]+"
- "[0-9]+.x"
paths-ignore:
- 'doc/**'
- 'src/Resources/public/**'
push:
branches:
- "[0-9]+.[0-9]+"
- "[0-9]+.x"
paths-ignore:
- 'doc/**'
- 'src/Resources/public/**'
env:
PIMCORE_PROJECT_ROOT: ${{ github.workspace }}
APP_ENV: test
PIMCORE_TEST: 1
# PIMCORE_TEST_DB_DSN: "mysql://[email protected]:33006/pimcore_test"
PIMCORE_TEST_REDIS_DSN: "redis://127.0.0.1:63379"
PIMCORE_TEST_CHROMIUM_DNS: 'ws://127.0.0.1:30000/'
PIMCORE_TEST_GOTENBERG_DNS: 'http://127.0.0.1:31234'
jobs:
codeception-tests:
name: "Codeception tests"
runs-on: "ubuntu-20.04"
continue-on-error: ${{ matrix.experimental }}
env:
PIMCORE_TEST_DB_DSN: "mysql://[email protected]:33006/pimcore_test"
strategy:
matrix:
include:
- { php-version: 8.1, database: "mariadb:10.3", dependencies: lowest, experimental: false }
- { php-version: 8.2, database: "mariadb:10.11", dependencies: highest, experimental: false }
- { php-version: 8.3, database: "mariadb:10.11", dependencies: highest, pimcore_version: "11.x-dev", experimental: true }
services:
redis:
image: redis
ports:
- 63379:6379
mariadb:
image: "${{ matrix.database }}"
ports:
- 33006:3306
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
chrome:
image: browserless/chrome
ports:
- "30000:3000"
gotenberg:
image: gotenberg/gotenberg:7
ports:
- "31234:3000"
steps:
- name: "Checkout code"
uses: "actions/checkout@v2"
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: "none"
extensions: imagick
ini-values: display_errors=On, display_startup_errors=On, error_reporting=32767
php-version: "${{ matrix.php-version }}"
- name: "Install Ghostscript and PDFInfo"
run: |
sudo apt-get update
sudo apt-get install -y ghostscript poppler-utils
- name: Verify MariaDB connection
run: |
cp .github/ci/files/.my.cnf ~/.my.cnf
while ! mysqladmin ping --silent; do
sleep 1
done
- name: "Setup Pimcore environment"
env:
DEPENDENCIES: "${{ matrix.dependencies }}"
run: |
mysql -e "CREATE DATABASE pimcore_test CHARSET=utf8mb4;"
.github/ci/scripts/setup-environment.sh
- name: "Update Pimcore version"
env:
PIMCORE_VERSION: "${{ matrix.pimcore_version }}"
run: |
if [ ! -z "$PIMCORE_VERSION" ]; then
composer require --no-update pimcore/pimcore:"${PIMCORE_VERSION}"
composer require --no-update pimcore/admin-ui-classic-bundle:1.x-dev
fi
- name: "Install dependencies with Composer"
uses: "ramsey/composer-install@v2"
with:
dependency-versions: "${{ matrix.dependencies }}"
- name: "Test environment infos"
run: |
mysql -e "SELECT VERSION();"
php -i
- name: "Sync Metadata Storage"
run: |
bin/console doctrine:migrations:sync-metadata-storage -vvv
- name: "Run Codeception"
run: "vendor/bin/codecept run -c . -vvv --xml"