File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed
Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change 6969if [ " $RSPEC_TEST " = " true" ]; then
7070 SAVED_PATH=" $PATH "
7171 RSPEC_EXITCODE=" 0"
72+ COVERAGE_EXITCODE=" 0"
7273 for pv in $PUPPET_VERSIONS ; do
7374 export PUPPET_VERSION=" $pv "
7475
@@ -106,6 +107,11 @@ if [ "$RSPEC_TEST" = "true" ]; then
106107
107108 # Quick coverage report
108109 cat " $DIR /coverage/coverage.txt"
110+ if grep -q " 100% test coverage. You're all set, friend" " $DIR /coverage/coverage.txt" ; then
111+ :
112+ else
113+ COVERAGE_EXITCODE=1
114+ fi
109115 echo " "
110116
111117 # To avoid travis getting hung if it gets confused, we'll run each of these
@@ -136,11 +142,16 @@ if [ "$RSPEC_TEST" = "true" ]; then
136142 rm -f " ${DIR} /.puppet_version"
137143else
138144 RSPEC_EXITCODE=-1
145+ COVERAGE_EXITCODE=-1
139146 echo " "
140147fi
141148
142149# Finish off script
143150echo " Finished script/cibuild:"
144- [ " $RUBOCOP_EXITCODE " -ge 0 ] && echo " - rubocop: exit ${RUBOCOP_EXITCODE} "
145- [ " $RSPEC_EXITCODE " -ge 0 ] && echo " - rspec: exit ${RSPEC_EXITCODE} "
146- if [ " $RUBOCOP_EXITCODE " -gt 0 ] || [ " $RSPEC_EXITCODE " -gt 0 ]; then exit 1; else exit 0; fi
151+ [ " $RUBOCOP_EXITCODE " -ge 0 ] && echo " - rubocop: exit ${RUBOCOP_EXITCODE} "
152+ [ " $RSPEC_EXITCODE " -ge 0 ] && echo " - rspec: exit ${RSPEC_EXITCODE} "
153+ [ " $COVERAGE_EXITCODE " -ge 0 ] && echo " - coverage: exit ${COVERAGE_EXITCODE} "
154+ if [ " $RUBOCOP_EXITCODE " -gt 0 ] || [ " $RSPEC_EXITCODE " -gt 0 ] || [ " $COVERAGE_EXITCODE " -gt 0 ]; then
155+ exit 1
156+ fi
157+ exit 0
You can’t perform that action at this time.
0 commit comments