Salome HOME
modif du choix des commandes
[tools/eficas.git] / Aster / lance_test.sh
index 2990ac5c3af87f9fcd57c1181ba3f8d1c95b66e9..743c70beb936b22adc56571184f127e4549bbd8c 100755 (executable)
@@ -1,23 +1,43 @@
 #unalias do
 #set -x
-for file in `ls /local/noyret/Install_Eficas/lescomm/*`
+version=NEW9
+passe=1
+rm -rf ./Batch/${version}/ok_${passe}
+rm -rf ./Batch/${version}/bad_${passe} 
+rm -rf ./Batch/${version}/badfile_${passe}
+rm -rf ./Batch/${version}/nt_${passe}
+for file in `cat ./Batch/${version}/aTester`
 do
-        print $file
-       filepath=$file
-       grep "VISU_EFICAS='NON'" $filepath > /dev/null 2>/dev/null
-       rc=$?
-       if [ "$rc" != "0" ]
-       then
-           grep INCLUDE $filepath | grep -v "#" | grep -v INCLUDE_MATERIAU > /dev/null 2>/dev/null
-           rc=$?
-           if  [ "$rc" != "0" ]
-           then
-                echo $file
-               ./test_eficas.py $filepath 
-           fi
-       fi
-#        read a; if [ "$a" == "b" ]  
-#      then  
-#         exit  
-#      fi 
+        echo $file
+        grep "VISU_EFICAS='NON'" $file > /dev/null 2>/dev/null
+        rc=$?
+        if [ "$rc" != "0" ]
+        then
+            grep INCLUDE $file | grep -v "#" | grep -v INCLUDE_MATERIAU > /dev/null 2>/dev/null
+            rc=$?
+            if  [ "$rc" != "0" ]
+            then
+                     cr=`./test_eficas.py $file` 
+                if [ "${cr}" == "" ]
+                then
+                  echo $file >> ./Batch/${version}/bad_${passe}
+                else
+                  nomfeuille=`basename $file`
+                  boncr="DEBUT CR validation : "${nomfeuille}" FIN CR validation :"${nomfeuille}
+                  cr=`echo $cr`
+                  if [ "${cr}" != "$boncr" ]
+                  then
+                        echo $file >> ./Batch/${version}/bad_${passe}
+                        echo $cr >>./Batch/${version}/bad_${passe}
+                        echo $file >>./Batch/${version}/badfile_${passe}
+                  else
+                        echo $file >> ./Batch/${version}/ok_${passe}
+                  fi
+                fi
+            else
+              echo $file >> ./Batch/${version}/nt_${passe}
+            fi
+        else
+           echo $file >> ./Batch/${version}/nt_${passe}
+        fi 
 done