datatool_xml.sh.in
上传用户:yhdzpy8989
上传日期:2007-06-13
资源大小:13604k
文件大小:1k
- #! /bin/sh
- # $Id: datatool_xml.sh.in,v 1000.0 2003/10/29 17:48:51 gouriano Exp $
- #
- base="${1:-@srcdir@/testdata}"
- if test ! -d $base; then
- echo "Error -- test data dir not found: $base"
- exit 1
- fi
- if test -d "$1"; then
- shift
- fi
- d="$base/data"
- r="$base/res"
- tool="datatool"
- for i in "idx" "elink" "note"; do
- echo "$tool" -m "$base/$i.dtd" -vx "$d/$i.xml" -px out
- cmd=`echo "$tool" -m "$base/$i.dtd" -vx "$d/$i.xml" -px out`
- time $cmd
- if test "$?" != 0; then
- echo "datatool failed!"
- exit 1
- fi
- cmp out "$r/$i.xml"
- if test "$?" != 0; then
- echo "wrong result!"
- exit 1
- fi
- done
- echo "Done!"
- #
- # ===========================================================================
- # PRODUCTION $Log: datatool_xml.sh.in,v $
- # PRODUCTION Revision 1000.0 2003/10/29 17:48:51 gouriano
- # PRODUCTION PRODUCTION: IMPORTED [ORIGINAL] Dev-tree R1.2
- # PRODUCTION
- # ===========================================================================
- #