-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun.sh
executable file
·36 lines (36 loc) · 1.32 KB
/
run.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
readarray -t testlist < testlist.txt
let i=0
list=""
. marathon.properties
if [[ $1 == "uat2" ]]
then
sed "s,marathon_jnlp,$marathon_jnlp_uat2,g" < Fixtures/default$.rb > Fixtures/default.rb
sed "s,marathon_host,$marathon_host_uat2,g" < Modules/modGeneral.1rb > Modules/modGeneral.rb
elif [[ $1 == "uat3" ]]
then
sed "s,marathon_jnlp,$marathon_jnlp_uat3,g" < Fixtures/default$.rb > Fixtures/default.rb
sed "s,marathon_host,$marathon_host_uat3,g" < Modules/modGeneral.1rb > Modules/modGeneral.rb
elif [[ $1 == "uat4" ]]
then
sed "s,marathon_jnlp,$marathon_jnlp_uat4,g" < Fixtures/default$.rb > Fixtures/default.rb
sed "s,marathon_host,$marathon_host_uat4,g" < Modules/modGeneral.1rb > Modules/modGeneral.rb
elif [[ $1 == "uat5" ]]
then
sed "s,marathon_jnlp,$marathon_jnlp_uat5,g" < Fixtures/default$.rb > Fixtures/default.rb
sed "s,marathon_host,$marathon_host_uat5,g" < Modules/modGeneral.1rb > Modules/modGeneral.rb
fi
while (( ${#testlist[@]} > i )); do
#printf "${testlist[i++]}"
a=${testlist[i++]};
skip=${a:0:1};
if [[ "${a}" == *#* ]]; then
printf "";
else
echo "$marathon_home/marathonite -capture -reportdir Reports -batch . ${list}"
list="${list} ${a}"
fi
done
echo "${list}"
cp TestCases/Complete/*.rb TestCases
"$marathon_home/marathonite" -capture -reportdir Reports -batch . ${list}
rm TestCases/*.rb