works
[fleet.git] / testCode / runOne.sh
1 #!/bin/sh
2
3 # Run one test on Marina
4 # Use the netlist generated from the schematic.
5 # First argument is integer specifying which test
6 # Second argument specifies mode: -exptSch -exptLay -chipSch -silicon
7
8 echo ------------------------------------------------------------------------------
9 echo Test number $1
10 (time java -classpath "MarinaTest.jar" com.sun.vlsi.chips.marina.test.MarinaTest -testNum $1 $2) >& test$1.log
11 if [ $? -ne 0 ] ; then
12   if [ $? -eq 1 ] ; then
13     # possibly buggy test
14     echo Crashed.
15   else
16     # test detected a hardware defect
17     echo Failed.
18   fi
19   ALL_PASSED=false
20   # save information so I can discover why test failed
21   mv marina.spi.out test$1.out
22   mv marina.spi.run test$1.run
23 else
24   echo Passed.
25 fi