-
-
Notifications
You must be signed in to change notification settings - Fork 6
/
.travis.yml
89 lines (76 loc) · 5.82 KB
/
.travis.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
87
88
89
# A Travis configuration file for a bundle which aims to be compatible with both eZPublish 5 and eZPlatform
language: php
services:
- mysql
env:
global:
- SYMFONY_ENV=behat
- DB_HOST=localhost
- DB_TYPE=mysql
- DB_EZ_USER=ezp
- DB_EZ_PASSWORD=ezp
- DB_EZ_DATABASE=behattestdb
# NB: see https://support.ibexa.co/Public/Service-Life for EOL dates of eZPublish versions
# and http://php.net/supported-versions.php for EOL dates of PHP versions
# About php versions:
# - php 5.6 _can_ be installed from epel/remi repos on RHEL/CentOS 6, which is the oldest currently supported (see at the bottom of https://access.redhat.com/support/policy/updates/errata)
# - Debian 8 comes with php 5.6 too - although it is _abandonware_ by now
# - Ubuntu 14 comes with php 5.5, and it is in extended support (ESM) until 2022. It might be possible to update it php 5.6 via ondrej ppa
# We thus still test on php 5.6
# We limit the matrix to one version of eZPublish for each version of PHP
# @todo where we have 2 minor versions of the same 'main version' tested, we should test the lower numbered one forcing composer to use the oldest possible dependencies
matrix:
include:
- php: 5.6
env: EZ_PACKAGES='ezsystems/ezpublish-community:~2014.11.1 ezsystems/behatbundle:~5.4' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
# eZPlatform 1 aka eZPublish 6 - earliest LTS release is 1.7
- php: 7.0
env: EZ_PACKAGES='ezsystems/ezplatform:~1.7.9 ezsystems/ezplatform-xmltext-fieldtype:^1.1 ezsystems/behatbundle:~6.3' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle EzSystems\EzPlatformXmlTextFieldTypeBundle\EzSystemsEzPlatformXmlTextFieldTypeBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
# last LTS version available of eZPlatform 1 - also an LTS
- php: 7.1
env: EZ_PACKAGES='ezsystems/ezplatform:~1.13.5 ezsystems/ezplatform-xmltext-fieldtype:^1.1 ezsystems/behatbundle:~6.3' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle EzSystems\EzPlatformXmlTextFieldTypeBundle\EzSystemsEzPlatformXmlTextFieldTypeBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
# eZPlatform 2 aka eZPublish 7
- php: 7.2
env: EZ_PACKAGES='ezsystems/ezplatform:~2.3.2 ezsystems/ezplatform-xmltext-fieldtype:^1.7 ezsystems/behatbundle:~6.5 sensio/generator-bundle ezsystems/repository-forms:<=2.4' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle EzSystems\EzPlatformXmlTextFieldTypeBundle\EzSystemsEzPlatformXmlTextFieldTypeBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
# next-to-latest version currently available of eZPlatform 2
- php: 7.3
env: EZ_PACKAGES='ezsystems/ezplatform:~2.4.2 ezsystems/ezplatform-xmltext-fieldtype:^1.8 ezsystems/behatbundle:~6.5 sensio/generator-bundle' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle EzSystems\EzPlatformXmlTextFieldTypeBundle\EzSystemsEzPlatformXmlTextFieldTypeBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
# latest version currently available of eZPlatform 2 - currently 2.5, which is also LTS
- php: 7.4
env: EZ_PACKAGES='ezsystems/ezplatform:^2.5.15 ezsystems/ezplatform-xmltext-fieldtype:^1.9 ezsystems/behatbundle:~7.0 sensio/generator-bundle overblog/graphiql-bundle' EZ_BUNDLES='Kaliop\eZObjectWrapperBundle\KaliopeZObjectWrapperBundle EzSystems\EzPlatformXmlTextFieldTypeBundle\EzSystemsEzPlatformXmlTextFieldTypeBundle Kaliop\eZMigrationBundle\EzMigrationBundle' EZ_TEST_CONFIG_SYMFONY=WrapperBundle/Tests/config/config_behat_bundle.yml
#allow_failures:
# this currently fails because of eZPublish services.yml not quoting usage of @, despite it being tested with Sf 2.8...
#- php: 7.0
before_install:
- sudo apt-get update
- sudo apt-get install -y zip unzip
# No need for a web server, until we start testing using Selenium
#- sudo apt-get install -qq -y --force-yes apache2 libapache2-mod-fastcgi
install:
- git clone --depth 1 --branch 0.3.1 https://github.com/tanoconsulting/euts.git teststack
# just in case...
- chmod 755 ./teststack/bin/*.sh ./teststack/bin/setup/*.sh
- ./teststack/bin/setup.sh
- ./teststack/bin/sfconsole.sh --env=behat kaliop:migration:migrate -n -u --path=./WrapperBundle/Tests/data/001_Content.yml
script:
# Finally! :-D
- if [ "$CODE_COVERAGE" = "1" ]; then ./teststack/bin/runtests.sh -c coverage.clover WrapperBundle/Tests/phpunit; else ./teststack/bin/runtests.sh WrapperBundle/Tests/phpunit; fi
after_failure:
# Display as much info as we can to help developers
- php -i
#- cat composer.lock
after_script:
# Upload code-coverage to Scrutinizer
- if [ "$CODE_COVERAGE" = "1" -a -f coverage.clover ]; then wget https://scrutinizer-ci.com/ocular.phar; fi
- if [ "$CODE_COVERAGE" = "1" -a -f coverage.clover ]; then php ocular.phar code-coverage:upload --format=php-clover coverage.clover; fi
# Upload code-coverage to CodeClimate. NB: this works only when the CODECLIMATE_REPO_TOKEN env var has been set (we do it in the Travis config via the GUI)
- if [ "$CODE_COVERAGE" = "1" -a -f coverage.clover ]; then ./vendor/bin/test-reporter --coverage-report=coverage.clover; fi
# Upload code-coverage to CodeCov
#- if [ "$CODE_COVERAGE" = "1" -a -f coverage.clover ]; then bash <(curl -s https://codecov.io/bash); fi
# reduce depth (history) of git checkout
git:
depth: 1
# Try to avoid problems with shared composer caches...
#cache:
# directories:
# - $COMPOSER_CACHE_DIR