python3: fix log index for test case messages

The post_test_hook.sh script was not ready for job suffixes like
-python35.

Change-Id: I9abf09f9ac2b572f610e07a439b8e5f6f63e1405
This commit is contained in:
Ihar Hrachyshka 2017-05-25 07:48:31 -07:00
parent 4a1d951920
commit fb6dd2bbe3

View File

@ -25,6 +25,19 @@ function generate_log_index {
xtrace=$(set +o | grep xtrace)
set +o xtrace
# honor job flavors like -python35
case $venv in
*"dsvm-fullstack"*)
venv="dsvm-fullstack"
;;
*"dsvm-functional"*)
venv="dsvm-functional"
;;
*)
echo "Unrecognized environment $venv".
exit 1
esac
virtualenv /tmp/os-log-merger
/tmp/os-log-merger/bin/pip install -U os-log-merger==1.1.0
files=$(find /opt/stack/logs/$venv-logs -name '*.txt' -o -name '*.log')