forked from jcraley/epviz
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_tests.sh
executable file
·75 lines (75 loc) · 3.76 KB
/
run_tests.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
green=`tput setaf 2`
cyan=`tput setaf 6`
reset=`tput sgr0`
find tests -name '*tests.py' -print0 |
while IFS= read -r -d '' line; do
echo "${line}"
if [[ $line = "tests/filter_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/filtering/filter_options.py
elif [[ $line = "tests/signal_loading_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/signal_loading/channel_options.py
python3 -m coverage report -m visualization/signal_loading/channel_info.py
elif [[ $line = "tests/plot_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/plot.py
elif [[ $line = "tests/plot_utils_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/plot_utils.py
elif [[ $line = "tests/stats_fs_band_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/signal_stats/signalStats_options.py
python3 -m coverage report -m visualization/signal_stats/signalStats_info.py
elif [[ $line = "tests/edf_saving_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/edf_saving/saveEdf_options.py
python3 -m coverage report -m visualization/edf_saving/saveEdf_info.py
python3 -m coverage report -m visualization/edf_saving/anonymizer.py
elif [[ $line = "tests/spectrogram_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/spectrogram_window/spec_options.py
elif [[ $line = "tests/prediction_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/predictions/prediction_options.py
python3 -m coverage report -m visualization/predictions/prediction_info.py
elif [[ $line = "tests/edf_loading_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/preprocessing/edf_loader.py
elif [[ $line = "tests/image_saving_tests.py" ]]
then
echo "${green} Running tests for ${line} ${reset}"
python3 -m coverage run "$line"
echo "${cyan} Coverage Report for ${line}"
python3 -m coverage report -m visualization/image_saving/saveImg_options.py
python3 -m coverage report -m visualization/image_saving/saveTopoplot_options.py
fi
done
echo "${reset}"