forked from sirdiego/importr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
74 lines (74 loc) · 2.89 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
language: php
php:
- 5.5
- 5.6
- 7
env:
- TYPO3_VERSION=^6.2.0 COVERAGE=0
- TYPO3_VERSION=^7.6.0 COVERAGE=0
matrix:
fast_finish: true
exclude:
- php: 7
env: TYPO3_VERSION=^6.2.0 COVERAGE=0
- php: 7
env: TYPO3_VERSION=^7.6.0 COVERAGE=0
include:
- php: 7
env: TYPO3_VERSION=^7.6.0 COVERAGE=1
- php: 7
env: TYPO3_VERSION=^8.1.0 COVERAGE=0
- php: 7
env: TYPO3_VERSION=dev-master COVERAGE=0
allow_failures:
- env: TYPO3_VERSION=dev-master COVERAGE=0
sudo: false
cache:
directories:
- "$HOME/.composer/cache"
before_install:
- |
if [[ "$COVERAGE" == "0" ]]; then
phpenv config-rm xdebug.ini
fi;
- composer self-update
- composer --version
- if [ "$GITHUB_COMPOSER_AUTH" ]; then composer config -g github-oauth.github.com
$GITHUB_COMPOSER_AUTH; fi
before_script:
- composer require typo3/cms=$TYPO3_VERSION
- export TYPO3_PATH_WEB="$PWD/.Build/Web"
script:
- |
echo; echo "Running unit tests";
if [[ "$COVERAGE" == "1" ]]; then
.Build/bin/phpunit -c Tests/UnitTests.xml --coverage-clover=.Build/unittest-coverage.clover
else
.Build/bin/phpunit -c Tests/UnitTests.xml
fi;
- |
echo; echo "Executing PHP mess detector"; .Build/bin/phpmd Classes/ text cleancode,codesize,controversial,design,naming || true
- |
echo; echo "Executing PHP code sniffer"; .Build/bin/phpcs --runtime-set ignore_warnings_on_exit true --standard=PSR2 Classes/
after_script:
- |
if [ -n "$TRAVIS_TAG" ] && [ -n "$TYPO3_ORG_USERNAME" ] && [ -n "$TYPO3_ORG_PASSWORD" ]; then
echo -e "Preparing upload of release ${TRAVIS_TAG} to TER\n"
curl -sSL https://raw.githubusercontent.com/alrra/travis-after-all/1.4.4/lib/travis-after-all.js | node
if [ $? -eq 0 ]; then
# Cleanup before we upload
git reset --hard HEAD && git clean -fx
TAG_MESSAGE=`git tag -n10 -l $TRAVIS_TAG | sed 's/^[0-9.]*[ ]*//g'`
echo "Uploading release ${TRAVIS_TAG} to TER"
.Build/bin/upload . "$TYPO3_ORG_USERNAME" "$TYPO3_ORG_PASSWORD" "$TAG_MESSAGE"
fi;
fi;
- |
if [[ "$COVERAGE" == "1" ]]; then
echo; echo "Uploading code coverage results";
.Build/bin/ocular code-coverage:upload --format=php-clover .Build/unittest-coverage.clover
fi
notifications:
email: false
slack:
secure: OkRMcSFGVYn5gRYJdRCUvMZu3sHVpF7/XcSDIOUfkULNXo8MTRso3bbALvqPve4qmOYxJIQfcn/2PK9jgq5PhE8qVfPZX9+5YuiN817L4o174BXi3Kx4Xh7fOUNNSQo9aqAKF65qaUDA3lD9BoHdPD37nP3fqNZMALOp4X+rxRWyAuwpAKSW+nDk+egnV21YkZe8af4nsFJMOUMcB/aX0Bzb9D5115JsWyBUEBpalHbtV7sbs3hxT1Q+qqEbxuHlNybG4Uxc6BbWuCzY1t3K5NWawX27/pIFBOLWGzTPrE4rXst59S0iGGply0fCUoTgM3A9uQZNuIxjO+BZbz1D4Or7xupMKG7cKu4KbWq3a6/+y2M/Fsn1GAjAHHWJZ2I6SWiQxpX1q/JGzIFw8LwwhAz0bLbNQIB0c/XImC17d0WY+0M4GcSkjszxo4WqlJzDA1BkGy2FhEUGNLWuny7erT9IZdX0VXiu+m0zfWLCbtdQ2cRu/DVQPLVMIY1CKo32Tguw4lCdIl89NeIgdt2rkWHCNiJOqloahgIAy4X7cj2tI85kNlP+es49e743gzt+pS5DjNXVryamluW+VdpKohjh+cucoiEytz/3xDHBN0gHTzgp2ApecUMDr0SuaSwnQbv6wmXLEERKmsxraak6c2HK3MxeP5iSBUbvn7kJ7nQ=