Commit 6dfb983c authored by Julien Lopez's avatar Julien Lopez

Includes xsltmark tests in the suite.

parent 9eaa25f4
......@@ -291,7 +291,7 @@ clean:
rm -f META
rm -rf lib
$(RM) tests/schema/regtest/test.cd tests/schema/regtest/test.log
$(RM) tests/schema/test.cd tests/schema/test.log tests/misc/log tests/misc/memento.html
$(RM) tests/schema/test.cd tests/schema/test.log tests/misc/log tests/misc/memento.html tests/xsltmark/log tests/cql/log
$(RM) oUnit-* tests/ocaml/a/c.ml tests/ocaml/a/c.cdo tests/ocaml/a/c.cmi tests/ocaml/a/c.cmo
for i in $(OUNIT_TESTS); do $(RM) `echo tests/ocaml/$$i/$$i tests/ocaml/$$i/$$i.ml tests/ocaml/$$i/$$i.c[dm][oxi] tests/ocaml/$$i/$${i}test.cm[io]`; done
......
......@@ -79,8 +79,8 @@ fi
echo -n "Tests on misc: "
SUCCESSMISC=0
TOTALMISC=0
SUCCESS=0
TOTAL=0
MISCLOG=$ROOT/misc/log
GOODTESTS="$ROOT/misc/addrbook.cd $ROOT/misc/biblio.cd\
$ROOT/misc/fixml4.3v20020920.cd $ROOT/misc/funs.cd $ROOT/misc/IFX130.cd\
......@@ -99,17 +99,47 @@ echo > $MISCLOG
if test $EXTENDED = "true"; then GOODTESTS="$GOODTESTS $EXTENDEDTESTS"; fi
for i in $GOODTESTS; do
TOTALMISC=$(($TOTALMISC+1))
TOTAL=$(($TOTAL+1))
echo "==============`echo $i | rev | cut -d "/" -f -1 | rev`===============" >> $MISCLOG;
$ROOT/../cduce $i > /dev/null 2>> $MISCLOG;
if test $? -eq 0; then SUCCESSMISC=$(($SUCCESSMISC+1)); fi
if test $? -eq 0; then SUCCESS=$(($SUCCESS+1)); fi
done
for i in $BADTESTS; do
TOTALMISC=$(($TOTALMISC+1))
TOTAL=$(($TOTAL+1))
echo "==============`echo $i | rev | cut -d "/" -f -1 | rev`===============" >> $MISCLOG;
$ROOT/../cduce $i > /dev/null 2>> $MISCLOG;
if test $? -ne 0; then SUCCESSMISC=$(($SUCCESSMISC+1)); fi
if test $? -ne 0; then SUCCESS=$(($SUCCESS+1)); fi
done
echo "$SUCCESSMISC / $TOTALMISC passed."
echo "$SUCCESS / $TOTAL passed."
# Test xsltmark
SUCCESS=0
TOTAL=0
XSLTLOG=$ROOT/xsltmark/log
GOODTESTS="$ROOT/xsltmark/identity.cd"
EXTENDEDTESTS="$ROOT/xsltmark/xslbench2.cd $ROOT/xsltmark/xslbench4.cd"
echo -n "Tests on xsltmark: "
echo > $XSLTLOG
if test $EXTENDED = "true"; then GOODTESTS="$GOODTESTS $EXTENDEDTESTS"; fi
for i in db100.xml db10.xml; do
TOTAL=$(($TOTAL+1))
echo "==============dbonerow.cd --arg $i===============" >> $XSLTLOG;
$ROOT/../cduce $ROOT/xsltmark/dbonerow.cd --arg $ROOT/xsltmark/testcases/$i > /dev/null 2>> $XSLTLOG;
if test $? -eq 0; then SUCCESS=$(($SUCCESS+1)); fi
done
for i in $GOODTESTS; do
TOTAL=$(($TOTAL+1))
echo "==============`echo $i | rev | cut -d "/" -f -1 | rev`===============" >> $XSLTLOG;
$ROOT/../cduce $i > /dev/null 2>> $XSLTLOG;
if test $? -eq 0; then SUCCESS=$(($SUCCESS+1)); fi
done
echo "$SUCCESS / $TOTAL passed."
......@@ -55,14 +55,9 @@ let fun dbonerow (<table> x : Table) : Xhtml =
)
]
match argv with
[ f ] -> (*load_xml f*)
match (argv []) with
(f,_) -> (*load_xml f*)
(match load_xml f with
| x & Table -> print_xml(dbonerow x)
| _ -> raise "Ma che c%$#^# di file mi hai passato?")
| _ -> raise "Please specify input file on command line"
......@@ -19,7 +19,7 @@ let fun identity (x : Table) : Table = x;;
match load_xml "testcases/db10000.xml" with
match load_xml "tests/xsltmark/testcases/db100.xml" with
| x & Table -> print_xml(identity x)
| _ -> raise "Ma che c%$#^# di file mi hai passato?";;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment