Commit 9be6d276 authored by Mikaël Salson's avatar Mikaël Salson

tests/launch_functional_tests: Allow to initialize tests before performing them

This is necessary for functional tests to reset the DB
parent 668bacac
Pipeline #97022 passed with stages
in 11 minutes and 3 seconds
......@@ -329,7 +329,7 @@ test_server_functional:
- cd docker/vidjil-server/conf/ && mv defs.py defs_https.py && mv defs_http.py defs.py && cd ../../..
- make germline && cp browser/js/germline.js docker/vidjil-client/conf
- cd docker && docker-compose up -d && cd ..
- sed -i "s/^python\ \.\.\/\.\.\/\.\./docker\ exec\ docker_uwsgi_1\ python\ \/usr\/share\/vidjil\/server\/web2py/" server/web2py/applications/vidjil/tests/init_func_test_db.sh
- sed -i "s/^python\ \.\.\/\.\.\/\.\./docker\ exec\ docker_uwsgi_1\ python\ \/usr\/share\/vidjil\/server\/web2py/" server/web2py/applications/vidjil/tests/init_tests.sh
- docker exec docker_uwsgi_1 sed -i "s/^\(FILE_SOURCE .*\)/FILE_SOURCE = '\/usr\/share\/vidjil\/demo'/" /usr/share/vidjil/server/web2py/applications/vidjil/modules/defs.py
- docker exec docker_nginx_1 make -C /usr/share/vidjil browser
- source /etc/profile.d/rvm.sh
......
......@@ -41,6 +41,7 @@ for browser in $BROWSER_LIST; do
echo "\033[1m\033[33m===== Testing browser: " $browser "\033[0m"
echo
for file in $FUNCTIONAL_TESTS; do
[ -f init_tests.sh ] && . ./init_tests.sh
echo "\033[34m===" $file "\033[0m"
if [ ${#browser} -gt 1 ]; then
export WATIR_BROWSER_PATH="$browser"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment