2005-02-10 Havoc Pennington <hp@redhat.com>
[platform/upstream/dbus.git] / dbus / dbus-test.c
index 8a99d17..e388310 100644 (file)
@@ -1,9 +1,9 @@
 /* -*- mode: C; c-file-style: "gnu" -*- */
 /* dbus-test.c  Program to run all tests
  *
- * Copyright (C) 2002, 2003  Red Hat Inc.
+ * Copyright (C) 2002, 2003, 2004, 2005  Red Hat Inc.
  *
- * Licensed under the Academic Free License version 1.2
+ * Licensed under the Academic Free License version 2.1
  * 
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -81,7 +81,7 @@ dbus_internal_do_not_use_run_tests (const char *test_data_dir)
     die ("strings");
 
   check_memleaks ();
-
+  
   printf ("%s: running sysdeps tests\n", "dbus-test");
   if (!_dbus_sysdeps_test ())
     die ("sysdeps");
@@ -100,21 +100,15 @@ dbus_internal_do_not_use_run_tests (const char *test_data_dir)
 
   check_memleaks ();
 
-  printf ("%s: running object ID tests\n", "dbus-test");
-  if (!_dbus_object_id_test ())
-    die ("object ID");
-  
-  check_memleaks ();
+  printf ("%s: running server listen tests\n", "dbus-test");
+  if (!_dbus_server_test ())
+    die ("server listen");
 
-  printf ("%s: running object registry tests\n", "dbus-test");
-  if (!_dbus_object_registry_test ())
-    die ("object registry");
-  
   check_memleaks ();
 
-  printf ("%s: running object tests\n", "dbus-test");
-  if (!_dbus_object_test ())
-    die ("object");
+  printf ("%s: running object tree tests\n", "dbus-test");
+  if (!_dbus_object_tree_test ())
+    die ("object tree");
   
   check_memleaks ();
   
@@ -124,35 +118,59 @@ dbus_internal_do_not_use_run_tests (const char *test_data_dir)
 
   check_memleaks ();
 
+#if 0
+  printf ("%s: running recursive marshalling tests\n", "dbus-test");
+  if (!_dbus_marshal_recursive_test ())
+    die ("recursive marshal");
+
+  check_memleaks ();
+#else
+  _dbus_warn ("recursive marshal tests disabled\n");
+#endif
+
+  printf ("%s: running byteswap tests\n", "dbus-test");
+  if (!_dbus_marshal_byteswap_test ())
+    die ("byteswap marshaled data");
+
+  check_memleaks ();
+  
   printf ("%s: running memory tests\n", "dbus-test");
   if (!_dbus_memory_test ())
     die ("memory");
   
   check_memleaks ();
 
+#if 1
   printf ("%s: running memory pool tests\n", "dbus-test");
   if (!_dbus_mem_pool_test ())
     die ("memory pools");
 
   check_memleaks ();
+#endif
   
   printf ("%s: running linked list tests\n", "dbus-test");
   if (!_dbus_list_test ())
     die ("lists");
 
   check_memleaks ();
+
+  printf ("%s: running validation tests\n", "dbus-test");
+  if (!_dbus_marshal_validate_test ())
+    die ("validation");
+
+  check_memleaks ();
+
+  printf ("%s: running header marshal tests\n", "dbus-test");
+  if (!_dbus_marshal_header_test ())
+    die ("header marshal");
+
+  check_memleaks ();
   
   printf ("%s: running message tests\n", "dbus-test");
   if (!_dbus_message_test (test_data_dir))
     die ("messages");
 
   check_memleaks ();
-
-  printf ("%s: running message handler tests\n", "dbus-test");
-  if (!_dbus_message_handler_test (test_data_dir))
-    die ("message handler");
-
-  check_memleaks ();
   
   printf ("%s: running hash table tests\n", "dbus-test");
   if (!_dbus_hash_test ())
@@ -209,5 +227,3 @@ dbus_internal_do_not_use_run_tests (const char *test_data_dir)
   printf ("Not compiled with unit tests, not running any\n");
 #endif
 }
-
-