Handle stestr execution for stackviz
This commit makes to handle a stestr execution for stackviz process. Tempest is now in the process of switching the tempest run command to use stestr internally instead of testrepository. This means that results will be stored in .stestr instead of .testrepository. So, this commit makes to handle a stestr or testrepository execution with checking which directory exists before attempting to process the subunit results. Change-Id: Ib19d3779deb89142e95762794dd1ce3fe3236b55
This commit is contained in:
parent
b376f17652
commit
cf8c872bb8
|
@ -557,13 +557,17 @@ function process_stackviz {
|
||||||
cp -r $stackviz_path/share/stackviz-html $log_path/stackviz
|
cp -r $stackviz_path/share/stackviz-html $log_path/stackviz
|
||||||
|
|
||||||
pushd $project_path
|
pushd $project_path
|
||||||
|
TEST_CMD="testr"
|
||||||
|
if [ -d ".stestr" ]; then
|
||||||
|
TEST_CMD="stestr"
|
||||||
|
fi
|
||||||
if [ -f $log_path/dstat-csv_log.txt ]; then
|
if [ -f $log_path/dstat-csv_log.txt ]; then
|
||||||
sudo testr last --subunit | $stackviz_path/bin/stackviz-export \
|
sudo $TEST_CMD last --subunit | $stackviz_path/bin/stackviz-export \
|
||||||
--dstat $log_path/dstat-csv_log.txt \
|
--dstat $log_path/dstat-csv_log.txt \
|
||||||
--env --stdin \
|
--env --stdin \
|
||||||
$log_path/stackviz/data
|
$log_path/stackviz/data
|
||||||
else
|
else
|
||||||
sudo testr last --subunit | $stackviz_path/bin/stackviz-export \
|
sudo $TEST_CMD last --subunit | $stackviz_path/bin/stackviz-export \
|
||||||
--env --stdin \
|
--env --stdin \
|
||||||
$log_path/stackviz/data
|
$log_path/stackviz/data
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue