/[pcre]/code/trunk/RunTest
ViewVC logotype

Diff of /code/trunk/RunTest

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

revision 836 by ph10, Wed Dec 28 17:16:11 2011 UTC revision 842 by ph10, Sat Dec 31 15:19:04 2011 UTC
# Line 18  Line 18 
18  # two tests for JIT-specific features, one to be run when JIT support is  # two tests for JIT-specific features, one to be run when JIT support is
19  # available, and one when it is not.  # available, and one when it is not.
20    
21  # Whichever of the 8-bit and 16-bit libraries exist are tested. It is also  # Whichever of the 8-bit and 16-bit libraries exist are tested. It is also
22  # possible to select which to test by the arguments -8 or -16.  # possible to select which to test by the arguments -8 or -16.
23    
24  # Other arguments for this script can be individual test numbers, or the word  # Other arguments for this script can be individual test numbers, or the word
# Line 32  sim= Line 32  sim=
32  arg8=  arg8=
33  arg16=  arg16=
34    
35    # This is in case the caller has set aliases (as I do - PH)
36    unset cp ls mv rm
37    
38  # Select which tests to run; for those that are explicitly requested, check  # Select which tests to run; for those that are explicitly requested, check
39  # that the necessary optional facilities are available.  # that the necessary optional facilities are available.
40    
# Line 77  while [ $# -gt 0 ] ; do Line 80  while [ $# -gt 0 ] ; do
80     17) do17=yes;;     17) do17=yes;;
81     18) do18=yes;;     18) do18=yes;;
82     19) do19=yes;;     19) do19=yes;;
83     20) do20=yes;;     20) do20=yes;;
84     -8) arg8=yes;;     -8) arg8=yes;;
85    -16) arg16=yes;;    -16) arg16=yes;;
86     valgrind) valgrind="valgrind -q --smc-check=all";;     valgrind) valgrind="valgrind -q --smc-check=all";;
# Line 190  if [ $utf -eq 0 ] ; then Line 193  if [ $utf -eq 0 ] ; then
193    fi    fi
194    if [ $do18 = yes ] ; then    if [ $do18 = yes ] ; then
195      echo "Can't run test 18 because UTF support is not configured"      echo "Can't run test 18 because UTF support is not configured"
196    fi    fi
197  fi  fi
198    
199  if [ $ucp -eq 0 ] ; then  if [ $ucp -eq 0 ] ; then
# Line 262  if [ $do1  = no -a $do2  = no -a $do3  = Line 265  if [ $do1  = no -a $do2  = no -a $do3  =
265    do17=yes    do17=yes
266    do18=yes    do18=yes
267    do19=yes    do19=yes
268    do20=yes    do20=yes
269  fi  fi
270    
271  # Show which release and which test data  # Show which release and which test data
# Line 277  for bmode in "$test8" "$test16"; do Line 280  for bmode in "$test8" "$test16"; do
280      -16)  if [ "$test8" != "skip" ] ; then echo ""; fi      -16)  if [ "$test8" != "skip" ] ; then echo ""; fi
281            bits=16; echo "---- Testing 16-bit library ----"; echo "";;            bits=16; echo "---- Testing 16-bit library ----"; echo "";;
282      *)    bits=8; echo "---- Testing 8-bit library ----"; echo "";;      *)    bits=8; echo "---- Testing 8-bit library ----"; echo "";;
283    esac    esac
284    
285  # Primary test, compatible with JIT and all versions of Perl >= 5.8  # Primary test, compatible with JIT and all versions of Perl >= 5.8
286    
287  if [ $do1 = yes ] ; then  if [ $do1 = yes ] ; then
# Line 581  if [ "$do14" = yes ] ; then Line 584  if [ "$do14" = yes ] ; then
584    echo "Test 14: specials for the basic 8-bit library"    echo "Test 14: specials for the basic 8-bit library"
585    if [ "$bits" = "16" ] ; then    if [ "$bits" = "16" ] ; then
586      echo "  Skipped when running 16-bit tests"      echo "  Skipped when running 16-bit tests"
587    elif [ $utf -eq 0 ] ; then    else
588      echo "  Skipped because UTF-$bits support is not available"      cp -f $testdata/saved16 testsaved16
   else  
589      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
590        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput14 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput14 testtry
591        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 607  if [ "$do15" = yes ] ; then Line 609  if [ "$do15" = yes ] ; then
609      echo "  Skipped when running 16-bit tests"      echo "  Skipped when running 16-bit tests"
610    elif [ $utf -eq 0 ] ; then    elif [ $utf -eq 0 ] ; then
611      echo "  Skipped because UTF-$bits support is not available"      echo "  Skipped because UTF-$bits support is not available"
612    else    else
613      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
614        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput15 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput15 testtry
615        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 631  if [ $do16 = yes ] ; then Line 633  if [ $do16 = yes ] ; then
633      echo "  Skipped when running 16-bit tests"      echo "  Skipped when running 16-bit tests"
634    elif [ $ucp -eq 0 ] ; then    elif [ $ucp -eq 0 ] ; then
635      echo "  Skipped because Unicode property support is not available"      echo "  Skipped because Unicode property support is not available"
636    else    else
637      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
638        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput16 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput16 testtry
639        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 653  if [ $do17 = yes ] ; then Line 655  if [ $do17 = yes ] ; then
655    echo "Test 17: specials for the basic 16-bit library"    echo "Test 17: specials for the basic 16-bit library"
656    if [ "$bits" = "8" ] ; then    if [ "$bits" = "8" ] ; then
657      echo "  Skipped when running 8-bit tests"      echo "  Skipped when running 8-bit tests"
658    else    else
659        cp -f $testdata/saved8 testsaved8
660        cp -f $testdata/saved16LE-1 testsaved16LE-1
661        cp -f $testdata/saved16BE-1 testsaved16BE-1
662      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
663        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput17 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput17 testtry
664        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 677  if [ $do18 = yes ] ; then Line 682  if [ $do18 = yes ] ; then
682      echo "  Skipped when running 8-bit tests"      echo "  Skipped when running 8-bit tests"
683    elif [ $utf -eq 0 ] ; then    elif [ $utf -eq 0 ] ; then
684      echo "  Skipped because UTF-$bits support is not available"      echo "  Skipped because UTF-$bits support is not available"
685    else    else
686        cp -f $testdata/saved16LE-2 testsaved16LE-2
687        cp -f $testdata/saved16BE-2 testsaved16BE-2
688      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
689        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput18 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput18 testtry
690        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 701  if [ $do19 = yes ] ; then Line 708  if [ $do19 = yes ] ; then
708      echo "  Skipped when running 8-bit tests"      echo "  Skipped when running 8-bit tests"
709    elif [ $ucp -eq 0 ] ; then    elif [ $ucp -eq 0 ] ; then
710      echo "  Skipped because Unicode property support is not available"      echo "  Skipped because Unicode property support is not available"
711    else    else
712      for opt in "" "-s" $jitopt; do      for opt in "" "-s" $jitopt; do
713        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput19 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput19 testtry
714        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 723  if [ $do20 = yes ] ; then Line 730  if [ $do20 = yes ] ; then
730    echo "Test 20: DFA specials for the basic 16-bit library"    echo "Test 20: DFA specials for the basic 16-bit library"
731    if [ "$bits" = "8" ] ; then    if [ "$bits" = "8" ] ; then
732      echo "  Skipped when running 8-bit tests"      echo "  Skipped when running 8-bit tests"
733    else    else
734      for opt in "" "-s"; do      for opt in "" "-s"; do
735        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput20 testtry        $sim $valgrind ./pcretest -q $bmode $opt $testdata/testinput20 testtry
736        if [ $? = 0 ] ; then        if [ $? = 0 ] ; then
# Line 741  fi Line 748  fi
748  # End of loop for 8-bit/16-bit tests  # End of loop for 8-bit/16-bit tests
749  done  done
750    
751    # Clean up local working files
752    rm -f test3input test3output testNinput testsaved* teststderr teststdout testtry
753    
754  # End  # End

Legend:
Removed from v.836  
changed lines
  Added in v.842

  ViewVC Help
Powered by ViewVC 1.1.5