-
Notifications
You must be signed in to change notification settings - Fork 63
/
.travis.yml
54 lines (47 loc) · 1.72 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
language: php
php: 8.1
env:
- TEST_GROUP=2-3-7
- TEST_GROUP=2-3-7-p4
- TEST_GROUP=2-4-0
- TEST_GROUP=2-4-1
- TEST_GROUP=2-4-2
- TEST_GROUP=2-4-3
- TEST_GROUP=2-4-4
- TEST_GROUP=2-4-5
- TEST_GROUP=2-4-6
- TEST_GROUP=2-4-6-p1
- TEST_GROUP=2-4-6-p2
- TEST_GROUP=2-4-6-p3
jobs:
allow_failures:
- env: TEST_GROUP=2-3-7-p4
- env: TEST_GROUP=2-3-7
# - env: TEST_GROUP=2-4-5
# - env: TEST_GROUP=2-4-6
before_install:
- travis_retry wget https://github.com/docker/compose/releases/download/v2.17.0/docker-compose-linux-x86_64
- sudo mv docker-compose-linux-x86_64 /usr/libexec/docker/cli-plugins/docker-compose
- sudo chmod +x /usr/libexec/docker/cli-plugins/docker-compose
- docker --version && docker compose version
install:
- composer install --no-interaction
- PHP_CS_FIXER_IGNORE_ENV=1 ./vendor/bin/php-cs-fixer fix --dry-run --rules=@PSR2 --diff src/
- vendor/bin/phpcs -s --standard=./ruleset.xml src/
- chmod 606 src/etc/db_schema_whitelist.json # so that docker container can write via volume
- TEST_GROUP=$TEST_GROUP composer docker-install-magento
- fileschanged=$(git ls-files -m -d | wc -l); if [[ ! "$fileschanged" -eq "0" ]]; then echo "Do you need to update the db_schema_whitelist.json file?" && git status && git --no-pager diff && sleep 5 && exit 1; fi
script:
- composer docker-configure-magento
- composer docker-run-codeception
- composer docker-run-unit-tests
- composer docker-run-integration-tests
cache:
directories:
- $HOME/.composer/cache
- $HOME/bin
after_failure:
- vendor/bin/mtest 'for r in /var/www/html/var/report/*; do cat $r; done'
- vendor/bin/mtest 'cat /var/www/html/var/log/*.log'
- docker ps
- sleep 10; # give log files time to render