mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-28 04:34:54 -04:00
capture more information from unit tests
- in unittest step, explicitly preserve kyua.log or atf.out - preserve kyua results database if present - generate HTML report from kyua results if available
This commit is contained in:
parent
91bfcb1aed
commit
cba2b972bc
3 changed files with 16 additions and 6 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
|
@ -21,9 +21,10 @@ ans.run
|
|||
named.run
|
||||
named.memstats
|
||||
gen.dSYM/
|
||||
.libs/
|
||||
.ccache/
|
||||
.deps/
|
||||
.dirstamp
|
||||
.libs/
|
||||
unit/atf-src/atf-c++/atf-c++.pc
|
||||
unit/atf-src/atf-c/atf-c.pc
|
||||
unit/atf-src/atf-c/defs.h
|
||||
|
|
|
|||
|
|
@ -97,6 +97,7 @@ stages:
|
|||
.system_test: &system_test_job
|
||||
stage: test
|
||||
before_script:
|
||||
- rm -rf .ccache
|
||||
- bash -x bin/tests/system/ifconfig.sh up
|
||||
script:
|
||||
- cd bin/tests && make -j${TEST_PARALLEL_JOBS:-1} -k test V=1
|
||||
|
|
@ -107,10 +108,18 @@ stages:
|
|||
|
||||
.unit_test: &unit_test_job
|
||||
stage: test
|
||||
before_script:
|
||||
- export KYUA_RESULT="$CI_PROJECT_DIR/kyua.results"
|
||||
script:
|
||||
- make unit
|
||||
after_script:
|
||||
- kyua report-html --force --results-file kyua.results --results-filter "" --output kyua_html
|
||||
artifacts:
|
||||
untracked: true
|
||||
paths:
|
||||
- atf.out
|
||||
- kyua.log
|
||||
- kyua.results
|
||||
- kyua_html/
|
||||
expire_in: '1 week'
|
||||
when: on_failure
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ if [ -n "@UNITTESTS@" -a -x "$ATFRUN" -a -f Atffile ]
|
|||
then
|
||||
echo "S:unit:`date`"
|
||||
echo "T:unit:1:A"
|
||||
echo "I: unit tests"
|
||||
echo "I: unit tests (using atf-run)"
|
||||
atf-run > atf.out
|
||||
status=$?
|
||||
|
||||
|
|
@ -29,11 +29,11 @@ elif [ -n "@UNITTESTS@" -a -x "$KYUA" -a -f Kyuafile ]
|
|||
then
|
||||
echo "S:unit:`date`"
|
||||
echo "T:unit:1:A"
|
||||
echo "I: unit tests"
|
||||
kyua --logfile kyua.log test
|
||||
echo "I: unit tests (using kyua)"
|
||||
kyua --logfile kyua.log --loglevel debug test --results-file ${KYUA_RESULT:-NEW}
|
||||
status=$?
|
||||
|
||||
kyua report
|
||||
kyua report --results-file ${KYUA_RESULT:-LATEST}
|
||||
|
||||
if [ $status -eq 0 ]
|
||||
then
|
||||
|
|
|
|||
Loading…
Reference in a new issue