init-tests.sh 1.09 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

cduceexec () {
  file=$1
  exec=$2
  base=`basename $file`
  dir=`dirname $file`
  mkdir -p _tests/$dir
  $exec -I $dir -c --verbose $file > _tests/$dir/${base%cd}cdi
  echo "$exec -I $dir -c --verbose $file > _tests/$dir/${base%cd}cdi"
}

TESTSMISC="misc/addrbook.cd misc/biblio.cd\
 misc/fixml4.3v20020920.cd misc/funs.cd misc/IFX130.cd\
 misc/integers.cd misc/lazy.cd misc/mc.cd\
 misc/memento.cd misc/notes.cd misc/ns.cd\
 misc/overloading.cd misc/overloading2.cd misc/patterns.cd\
 misc/security.cd misc/str.cd misc/stress_opt_arg.cd\
 misc/stress_opt_seq.cd misc/vouill.cd misc/web.cd\
 misc/wp.cd misc/xtrans.cd misc/ref.cd misc/xhtml.cd"

TESTSCQL="cql/TREE/*.cd cql/XMP/*.cd"

TESTSXSLRMARK="xsltmark/identity.cd"

TESTSTDLIB="stdlib/*.cd"

TESTPOLY="poly/*.cd"

for f in $TESTSMISC $TESTSXSLRMARK; do
  cduceexec $f cduce
done

for f in $TESTSCQL; do
  dir=`dirname $f`
  file=`basename $f`
  for i in `find $dir -name $file`; do
    cduceexec $i cduce
  done
done

for f in $TESTSTDLIB; do
  dir=`dirname $f`
  file=`basename $f`
  for i in `find $dir -name $file`; do
    cduceexec $i ../cduce
  done
done