/[escript]/branches/windows_from_1456_trunk_1544_merged_in/autotest-scons
ViewVC logotype

Diff of /branches/windows_from_1456_trunk_1544_merged_in/autotest-scons

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 356 by jgs, Wed Dec 14 05:37:24 2005 UTC revision 683 by robwdcock, Mon Mar 27 05:46:50 2006 UTC
# Line 4  Line 4 
4  # An explicit testing script for esys using the scons build system  # An explicit testing script for esys using the scons build system
5    
6  # list of users to email test results to  # list of users to email test results to
7  MAIL_RECIPIENTS="jgs@esscc.uq.edu.au gross@esscc.uq.edu.au cochrane@esscc.uq.edu.au elspeth@esscc.uq.edu.au matt@esscc.uq.edu.au"  MAIL_RECIPIENTS="gross@esscc.uq.edu.au elspeth@esscc.uq.edu.au matt@esscc.uq.edu.au robert.woodcock@csiro.au Peter.Hornby@csiro.au"
 #MAIL_RECIPIENTS="jgs@esscc.uq.edu.au"  
   
 # modules to test  
 TESTS="escript bruce finley"  
8    
9  # the python tests to run  # the python tests to run
10  FINLEY_PYTESTS="ImportTest.py finleyTest.py SimpleSolve.py GradTest.py RecTest.py test_linearPDEsOnFinley.py test_generators.py test_visualization_interface.py test_utilOnFinley.py test_symbolsOnFinley.py"  BRUCE_PYTESTS="ImportTest.passed BruceTest.passed test_utilOnBruce.py"
11  ESCRIPT_PYTESTS="ImportTest.py BinaryOps.py UnaryOps.py SliceGetting.py SliceSetting.py MiscTests.py ArchiveTests.py escriptTest.py newEscriptTests.py DataVariableTests.py test_xml.py"  ESCRIPT_PYTESTS="ImportTest.passed BinaryOps.passed UnaryOps.passed SliceGetting.passed SliceSetting.passed MiscTests.passed ArchiveTests.passed newEscriptTests.passed test_xml.passed insituTests.passed s2.passed"
12  BRUCE_PYTESTS="ImportTest.py BruceTest.py test_utilOnBruce.py test_symbolsOnBruce.py"  FINLEY_PYTESTS="ImportTest.passed finleyTest.passed SimpleSolve.passed RecTest.passed test_linearPDEsOnFinley.passed test_generators.passed test_visualization_interface.passed test_utilOnFinley.passed"
13    
14  echo cd $1  echo "===> cd $1"
15  cd $1  cd $1
16  if [ $? != 0 ]  if [ $? != 0 ]
17  then  then
18    echo couldnt cd $1    echo "couldnt cd $1"
19    echo "couldnt cd $1" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS    echo "couldnt cd $1" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
20    exit 1    exit 1
21  fi  fi
22    
23  PWD=`pwd`  PWD=`pwd`
24  echo working in: $PWD  echo "===> working in: $PWD"
25    
26    # Setup the environment
27    . ${MODULESHOME}/init/sh
28    module load intel_cc.9.0.026
29    export MODULEPATH=${MODULEPATH}:/data/raid2/toolspp4/modulefiles/gcc-3.3.6
30    module load boost/1.33.0/python-2.4.1
31    module load python/2.4.1
32    module load numarray/1.3.3
33    
34  # define compiler executable and library locations  # set openmp settings
 export PATH=/opt/intel/cmplrs/80.058/intel_cc_80/bin:$PATH  
 export LD_LIBRARY_PATH=/opt/intel/cmplrs/80.058/intel_cc_80/lib  
   
 # define python location  
 export PATH=/raid2/tools/python-2.3.4/bin:$PATH  
   
 # set library and openmp settings  
 export LD_LIBRARY_PATH=$PWD/lib:/raid2/tools/boost/lib:$LD_LIBRARY_PATH  
 export PYTHONPATH=$PWD  
35  export OMP_SCHEDULE="dynamic"  export OMP_SCHEDULE="dynamic"
36  export OMP_NUM_THREADS=4  export OMP_NUM_THREADS=4
37  export OMP_DYNAMIC=TRUE  export OMP_DYNAMIC=TRUE
38  export OMP_NESTED=FALSE  export OMP_NESTED=FALSE
39    
40  FAIL=0  echo "===> svn update"
   
 echo running svn update  
41  svn update  svn update
42  if [ $? != 0 ]  if [ $? != 0 ]
43  then  then
44    echo svn update failed    echo "svn update failed"
45    echo "svn update failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS    echo "svn update failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
46    exit 2    exit 2
47  fi  fi
48    
49  echo running scons debug=1  echo "===> scons building esys"
50  scons debug=1  scons
 scons debug=1 build_tests  
51  if [ $? != 0 ]  if [ $? != 0 ]
52  then  then
53    echo scons failed    echo "scons build failed"
54    echo "scons failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS    echo "scons build failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
55    exit 3    exit 3
56  fi  fi
57    
58  echo running bruce unit_tests  echo "===> building unit_tests"
59  cd bruce/test  scons build_tests
 ./unit_test-scons  
60  if [ $? != 0 ]  if [ $? != 0 ]
61  then  then
62    echo bruce unit_test failed    echo "unit_test build failed"
63    echo "bruce unit_test failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS    echo "unit_test build failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
64    FAIL=1    exit 3
65  fi  fi
 cd ../..  
66    
67  echo running escript unit_tests  FAIL=0
 cd escript/test  
 ./unit_test-scons  
 if [ $? != 0 ]  
 then  
   echo escript unit_test failed  
   echo "escript unit_test failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS  
   FAIL=1  
 fi  
 cd ../..  
68    
69  echo running finley unit_tests  echo "===> running unit_tests"
70  cd finley/test  scons run_tests
 ./unit_test-scons  
71  if [ $? != 0 ]  if [ $? != 0 ]
72  then  then
73    echo finley unit_test failed    echo "unit_testing failed"
74    echo "finley unit_test failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS    echo "unit_test failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
75    FAIL=1    FAIL=1
76  fi  fi
 cd ../..  
77    
78  echo running esysUtils unit_tests  for pytest in $ESCRIPT_PYTESTS
79  cd esysUtils/test  do
80  ./unit_test-scons    echo "===>running escript python test: $pytest"
81  if [ $? != 0 ]    scons build/posix/escript/test/python/$pytest
82  then    if [ $? != 0 ]
83    echo esysUtils unit_test failed    then
84    echo "esysUtils unit_test failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS      echo "python testing failed for $pytest in module $module"
85    FAIL=1      echo "escript py_test: $pytest failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
86  fi      FAIL=1
87  cd ../..    fi
88    done
89    
90    for pytest in $FINLEY_PYTESTS
91    do
92      echo "running finley python test: $pytest"
93      scons build/posix/finley/test/python/$pytest
94      if [ $? != 0 ]
95      then
96        echo "python testing failed for $pytest in module $module"
97        echo "finley py_test: $pytest failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
98        FAIL=1
99      fi
100    done
101    
102  for module in $TESTS  for pytest in $BRUCE_PYTESTS
103  do  do
104      echo "running python tests for: $module"    echo "running bruce python test: $pytest"
105      cd $module/test/python    scons build/posix/bruce/test/python/$pytest
106      if [ "$module" == "finley" ]    if [ $? != 0 ]
107      then    then
108          for pytest in $FINLEY_PYTESTS      echo "python testing failed for $pytest in module $module"
109          do      echo "bruce py_test: $pytest failed" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS
110              echo "Running python test: $pytest"      FAIL=1
111              python $pytest    fi
             if [ $? != 0 ]  
             then  
               echo Python Testing FAILED for $pytest in module $module  
               echo "finley py_test: $pytest failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS  
               FAIL=1  
             fi  
         done  
     elif [ "$module" == "escript" ]  
     then  
         for pytest in $ESCRIPT_PYTESTS  
         do  
             echo "Running python test: $pytest"  
             python $pytest  
             if [ $? != 0 ]  
             then  
               echo Python Testing FAILED for $pytest in module $module  
               echo "escript py_test: $pytest failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS  
               FAIL=1  
             fi  
         done  
     elif [ "$module" == "bruce" ]  
     then  
         for pytest in $BRUCE_PYTESTS  
         do  
             echo "Running python test: $pytest"  
             python $pytest  
             if [ $? != 0 ]  
             then  
               echo Python Testing FAILED for $pytest in module $module  
               echo "bruce py_test: $pytest failed - see autotest-scons logfile" | mail -s "esys autotest-scons results" $MAIL_RECIPIENTS  
               FAIL=1  
             fi  
         done  
     fi  
     cd ../../..  
112  done  done
113    
114  if [ $FAIL == 0 ]  if [ $FAIL == 0 ]

Legend:
Removed from v.356  
changed lines
  Added in v.683

  ViewVC Help
Powered by ViewVC 1.1.26