Skip to content

Commit a3b9b3e

Browse files
committed
Only update codecov stats on proper live test.
1 parent e4c9de1 commit a3b9b3e

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

.travis.yml

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -39,22 +39,14 @@ install:
3939

4040
before_script:
4141
- mysql -u root -e 'create database telegrambot; use telegrambot; source ./vendor/longman/telegram-bot/structure.sql;'
42+
- if [[ "$COVERAGE" == "1" ]] && [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then CODECOV="1"; fi
4243

4344
script:
4445
- composer check-code
45-
- |
46-
if [[ "$COVERAGE" == "1" ]]; then
47-
if [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then
48-
composer test-cov-live
49-
else
50-
composer test-cov
51-
fi
52-
else
53-
composer test
54-
fi
46+
- if [[ "$CODECOV" == "1" ]]; then composer test-cov-live; else composer test; fi
5547

5648
after_success:
57-
- if [[ "$COVERAGE" == "1" ]]; then composer test-cov-upload; fi
49+
- if [[ "$CODECOV" == "1" ]]; then composer test-cov-upload; fi
5850

5951
env:
6052
global:

0 commit comments

Comments
 (0)