Added YAZ_CHECK_TERM which terminates test program. Using yaz/test.h
[yaz-moved-to-github.git] / test / tstxmlquery.c
index c84d1e9..9aec56b 100644 (file)
@@ -2,7 +2,7 @@
  * Copyright (C) 1995-2005, Index Data ApS
  * See the file LICENSE for details.
  *
- * $Id: tstxmlquery.c,v 1.2 2006-01-27 18:58:58 adam Exp $
+ * $Id: tstxmlquery.c,v 1.4 2006-01-29 21:59:13 adam Exp $
  */
 
 #include <stdlib.h>
@@ -13,7 +13,6 @@
 #include <yaz/pquery.h>
 #include <yaz/test.h>
 
-#if HAVE_XML2
 static void pqf2xml_text(const char *pqf)
 {
     YAZ_PQF_Parser parser = yaz_pqf_create();
@@ -35,8 +34,10 @@ static void pqf2xml_text(const char *pqf)
     query->u.type_1 = rpn;
 
     odr_destroy(odr);
-}
+#if HAVE_XML2
+
 #endif
+}
 
 int main (int argc, char **argv)
 {
@@ -44,8 +45,7 @@ int main (int argc, char **argv)
 
     pqf2xml_text("@attr 1=4 computer");
 
-    exit(0);
-    return 0;
+    YAZ_CHECK_TERM;
 }
 
 /*