Bläddra i källkod

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

Chris Pepper 6 år sedan
förälder
incheckning
6b1967ed33
1 ändrade filer med 4 tillägg och 2 borttagningar
  1. 4
    2
      buildroot/share/tests/start_tests

+ 4
- 2
buildroot/share/tests/start_tests Visa fil

@@ -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

Laddar…
Avbryt
Spara