forked from extcode/cart
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
86 lines (76 loc) · 2.59 KB
/
.gitlab-ci.yml
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
cache:
key: "$CI_COMMIT_REF_NAME/$CI_JOB_STAGE"
paths:
- .composer/
- .php_cs.cache
variables:
COMPOSER_CACHE_DIR: ".composer"
TYPO3_PATH_WEB: "$CI_PROJECT_DIR/.Build/Web"
MYSQL_DATABASE: "typo3"
MYSQL_ROOT_PASSWORD: "joh316"
typo3DatabaseName: "typo3"
typo3DatabaseHost: "mysql"
typo3DatabaseUsername: "root"
typo3DatabasePassword: "joh316"
before_script:
- apk add git --update
stages:
- test
test:cgl:
image: composer:1.3
stage: test
before_script:
- composer remove typo3/cms-core --no-update
- composer install
script:
- .Build/bin/php-cs-fixer fix --config=Build/.php_cs -v --dry-run --using-cache=no --path-mode=intersection ./
.test: &test_php
stage: test
services:
- mysql:5
image: php:$DOCKER_TAG
only:
- branches
before_script:
- apk --no-cache add bash curl git mercurial openssh openssl parallel subversion tini
- docker-php-ext-install mysqli
- wget https://composer.github.io/installer.sig -O - -q | tr -d '\n' > installer.sig
- php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
- php -r "if (hash_file('SHA384', 'composer-setup.php') === trim(file_get_contents('installer.sig'))) { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
- php composer-setup.php --no-ansi --install-dir=/usr/bin --filename=composer
- php -r "unlink('composer-setup.php'); unlink('installer.sig');"
- composer require typo3/cms="${TYPO3_VERSION}"
script:
- .Build/bin/phpunit -c .Build/vendor/nimut/testing-framework/res/Configuration/UnitTests.xml Tests/Unit
- find . -name \*.php ! -path "./.Build/*" | parallel --gnu php -d display_errors=stderr -l {} > /dev/null
- find 'Tests/Functional' -wholename '*Test.php' | parallel --gnu 'echo; echo "Running functional test suite {}"; .Build/bin/phpunit --colors -c .Build/vendor/nimut/testing-framework/res/Configuration/FunctionalTests.xml {}'
# Build in PHP 5.6 and TYPO3 7.6
test:php56:typo3_7:
<<: *test_php
variables:
DOCKER_TAG: 5.6-alpine
TYPO3_VERSION: ^7.6
# Build in PHP 7.0 and TYPO3 7.6
test:php70:typo3_7:
<<: *test_php
variables:
DOCKER_TAG: 7.0-alpine
TYPO3_VERSION: ^7.6
# Build in PHP 7.1 and TYPO3 7.6
test:php71:typo3_7:
<<: *test_php
variables:
DOCKER_TAG: 7.1-alpine
TYPO3_VERSION: ^7.6
# Build in PHP 7.0 and TYPO3 8.7
test:php70:typo3_8:
<<: *test_php
variables:
DOCKER_TAG: 7.0-alpine
TYPO3_VERSION: ^8.7
# Build in PHP 7.1 and TYPO3 8.7
test:php71:typo3_8:
<<: *test_php
variables:
DOCKER_TAG: 7.1-alpine
TYPO3_VERSION: ^8.7