Diff of /tests/run_tests_travis.sh [000000] .. [5d12a0]

Switch to unified view

a b/tests/run_tests_travis.sh
1
#!/usr/bin/env bash
2
set -e
3
4
PYCMD=${PYCMD:="python3"}
5
COVERAGE=0
6
while [[ "$#" -gt 0 ]]; do
7
    case "$1" in
8
        -p|--python) PYCMD=$2; shift 2 ;;
9
        -c|--coverage) COVERAGE=1; shift 1;;
10
        --) shift; break ;;
11
        *) echo "Invalid argument: $1!" ; exit 1 ;;
12
    esac
13
done
14
15
if [[ $COVERAGE -eq 1 ]]; then
16
    coverage erase
17
    PYCMD="coverage run --parallel-mode --source ants "
18
    echo "coverage flag found. Setting command to: \"$PYCMD\""
19
fi
20
21
pushd "$(dirname "$0")"
22
23
echo "Running core tests"
24
$PYCMD test_core_ants_image.py $@
25
$PYCMD test_core_ants_image_io.py $@
26
$PYCMD test_core_ants_transform.py $@
27
$PYCMD test_core_ants_transform_io.py $@
28
$PYCMD test_core_ants_metric.py $@
29
30
# echo "Running learn tests"
31
# $PYCMD test_learn.py $@
32
33
# echo "Running registation tests"
34
# $PYCMD test_registation.py $@
35
36
# echo "Running segmentation tests"
37
# $PYCMD test_segmentation.py $@
38
39
echo "Running utils tests"
40
$PYCMD test_utils.py $@
41
42
echo "Running bug tests"
43
$PYCMD test_bugs.py $@
44
45
46
47
if [[ $COVERAGE -eq 1 ]]; then
48
    coverage combine
49
    coverage html
50
fi
51
52
53
popd