blob: 19cc8ef110c0124cae0c72d0e62c4b3acfda47b9 [file] [log] [blame]
Victor Moralesdd074802017-07-26 16:06:35 -05001#!/bin/bash
2
3source /var/onap/asserts
4
5# main() - Starting point for Unit Tests
6function main {
7 local covered_functions=("$@")
8
9 len=${#covered_functions[@]}
10 echo "1..$len"
11 for i in ${!covered_functions[@]}; do
12 dpkg --get-selections > installed-software
13 sort -o installed-software installed-software
14 test_${covered_functions[$i]}
15 echo "ok $((i+1)) - test_${covered_functions[$i]}"
16
17 # Teardown process
18 dpkg --get-selections > installed-software_new
19 sort -o installed-software_new installed-software_new
20 apt-get purge -y -qq $(comm -3 installed-software installed-software_new | awk '{print $1}')
21 #rm -rf $git_src_folder
22 #rm -rf ~/.m2/
23 done
24}