Browse Source

Add back in the Env backup restore around each platforms tests (#11980)

Chris Pepper 6 years ago
parent
commit
6b1967ed33
1 changed files with 4 additions and 2 deletions
  1. 4
    2
      buildroot/share/tests/start_tests

+ 4
- 2
buildroot/share/tests/start_tests View File

@@ -18,7 +18,6 @@ exec_test () {
18 18
 }
19 19
 export -f exec_test
20 20
 
21
-env_backup
22 21
 printf "Running \033[0;32m$2\033[0m Tests\n"
23 22
 
24 23
 if [[ $3 = "--deep-clean" ]]; then
@@ -30,14 +29,17 @@ if [[ $2 = "ALL" ]]; then
30 29
   dir_list=("$(dirname "${BASH_SOURCE[0]}")"/*)
31 30
   declare -a tests=(${dir_list[@]/*start_tests/})
32 31
   for f in "${tests[@]}"; do
32
+    env_backup
33 33
     testenv=$(basename $f | cut -d"_" -f1)
34 34
     printf "Running \033[0;32m$f\033[0m Tests\n"
35 35
     exec_test $1 "$testenv --target clean" "Setup Build Environment"
36 36
     $f $1 $testenv
37
+    env_restore
37 38
   done
38 39
 else
40
+  env_backup
39 41
   exec_test $1 "$2 --target clean" "Setup Build Environment"
40 42
   $2_tests $1 $2
43
+  env_restore
41 44
 fi
42 45
 printf "\033[0;32mAll tests completed successfully\033[0m\n"
43
-env_restore

Loading…
Cancel
Save