mirror of
https://dev.iopsys.eu/bbf/icwmp.git
synced 2025-12-10 07:44:41 +01:00
44 lines
820 B
Bash
Executable file
44 lines
820 B
Bash
Executable file
#!/bin/bash
|
|
|
|
echo "preparation script"
|
|
pwd
|
|
. ./gitlab-ci/shared.sh
|
|
|
|
trap cleanup EXIT
|
|
trap cleanup SIGINT
|
|
|
|
echo "Compiling icmwp"
|
|
build_icwmp
|
|
|
|
mkdir -p /var/state/icwmpd
|
|
|
|
echo "Starting Services..."
|
|
cp ./gitlab-ci/icwmp.conf /etc/supervisor/conf.d/
|
|
supervisorctl reread
|
|
supervisorctl update
|
|
sleep 10
|
|
supervisorctl status all
|
|
|
|
# wait until cwmp status is up
|
|
check_cwmp_status
|
|
|
|
echo "Running the api test cases"
|
|
ubus-api-validator -t 10 -f ./test/api/json/tr069.validation.json > ./api-test-result.log
|
|
check_ret $?
|
|
|
|
sleep 5
|
|
|
|
echo "Stop all services"
|
|
supervisorctl stop icwmpd
|
|
|
|
# Artefact
|
|
gcovr -r . 2> /dev/null --xml -o ./api-test-coverage.xml
|
|
#GitLab-CI output
|
|
gcovr -r . 2> /dev/null
|
|
|
|
#report part
|
|
exec_cmd tap-junit --input ./api-test-result.log --output report
|
|
|
|
check_valgrind_xml
|
|
|
|
echo "Functional API test :: PASS"
|