Skip to content

Commit 191c11a

Browse files
committedMar 4, 2017
[travis] Colorize test results
1 parent b6e8777 commit 191c11a

File tree

3 files changed

+56
-1
lines changed

3 files changed

+56
-1
lines changed
 

‎.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ matrix:
3737
- txt2tags
3838
- xvfb
3939
- clang-3.8
40+
- grc
4041

4142

4243
- os: linux

‎ci/travis/linux/.grc.colors

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# A readme that explains the configuration options can be found here
2+
# http://korpus.juls.savba.sk/~garabik/software/grc/README.txt
3+
4+
####################
5+
# Early exit, lines that do not need to be processed further
6+
####################
7+
8+
# DEFAULT: the final FAILED line in failed nose tests
9+
regexp=^FAILED (failures=[0-9])$
10+
colours=default
11+
count=stop
12+
-
13+
14+
###################
15+
# Failed test block
16+
###################
17+
18+
# YELLOW: A test failed, start a yellow block
19+
regexp=^FAIL[:\!].*
20+
colours=yellow
21+
count=block
22+
-
23+
# YELLOW END: End block on next successful test
24+
regexp=^PASS
25+
colours=default
26+
count=unblock
27+
-
28+
# YELLOW END: End block on next successful test
29+
regexp=^Ran
30+
colours=default
31+
count=unblock
32+
-
33+
34+
####################
35+
# Unit test name (title)
36+
####################
37+
38+
# RED: test name
39+
regexp=.*Test.*\*\*\*Failed.*sec
40+
colours=red
41+
-
42+
43+
####################
44+
# Successful tests
45+
####################
46+
47+
# DARK GRAY: passed tests should be unobtrusive
48+
regexp=.*Test.*Passed.*sec
49+
colours="\033[90m"
50+
-
51+
# DARK GRAY: Start test lines should be unobtrusive
52+
regexp=\s{8}Start.*
53+
colours="\033[90m"

‎ci/travis/linux/script.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,6 @@ if [ "$CACHE_WARMING" = true ] ; then
3232
xvfb-run ctest -V -R NOTESTS -S ./qgis-test-travis.ctest --output-on-failure
3333
false
3434
else
35-
xvfb-run ctest -V -E "$(cat ${DIR}/blacklist.txt | sed -r '/^(#.*?)?$/d' | paste -sd '|' -)" -S ./qgis-test-travis.ctest --output-on-failure
35+
grc -c ${TRAVIS_BUILD_DIR}/ci/travis/linux/.grc.colors \
36+
xvfb-run ctest -V -E "$(cat ${DIR}/blacklist.txt | sed -r '/^(#.*?)?$/d' | paste -sd '|' -)" -S ./qgis-test-travis.ctest --output-on-failure
3637
fi

0 commit comments

Comments
 (0)
Please sign in to comment.