forked from dotmailer/dotmailer-magento2-extension
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
39 lines (30 loc) · 1.32 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
dist: trusty
language: php
sudo: false
php:
- 5.6
- 7.0
env:
matrix:
- TEST_SUITE=unit
- TEST_SUITE=static
matrix:
exclude:
- php: 7.0
env: TEST_SUITE=static
cache:
directories:
- $HOME/.composer/cache
install:
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then composer install --prefer-dist; fi"
- sh -c "if [ '$TEST_SUITE' = 'static' ]; then npm install; fi"
script:
- wget https://gist.githubusercontent.com/cdiacon/457f0e09fb936e5cc859/raw/a9d46ee07b550b9a742a3cb418c28b5d49b1753b/auth.json
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/phpdoc run -d Block,Helper,Model,Observer -t build/doc; fi"
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/phpcs; fi"
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/phpmd Block/,Helper/,Model/,Observer/,Test/ text cleancode,codesize,controversial,design,naming,unusedcode; fi"
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/phpcpd Block/ Helper/ Model/ Observer/ Test/; fi"
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/phpunit --coverage-clover build/logs/clover.xml; fi"
- sh -c "if [ '$TEST_SUITE' = 'static' ]; then ./node_modules/.bin/grunt ci; fi"
after_script:
- sh -c "if [ '$TEST_SUITE' = 'unit' ]; then php vendor/bin/coveralls; fi"