[Galago-commits] r2564 - in branches/libgalago/protocol-cleanup: . tests

galago-commits at freedesktop.org galago-commits at freedesktop.org
Tue Feb 7 01:05:28 PST 2006


Author: chipx86
Date: 2006-02-07 01:04:32 -0800 (Tue, 07 Feb 2006)
New Revision: 2564

Modified:
   branches/libgalago/protocol-cleanup/ChangeLog
   branches/libgalago/protocol-cleanup/tests/check-libgalago.c
Log:
Beef up the unit tests by registering as a feed and ensuring that objects can be created with valid returned object paths.


Modified: branches/libgalago/protocol-cleanup/ChangeLog
===================================================================
--- branches/libgalago/protocol-cleanup/ChangeLog	2006-02-07 08:51:00 UTC (rev 2563)
+++ branches/libgalago/protocol-cleanup/ChangeLog	2006-02-07 09:04:32 UTC (rev 2564)
@@ -1,3 +1,9 @@
+Tue Feb 07 01:04:02 PST 2006  Christian Hammond <chipx86 at chipx86.com>
+
+	* tests/check-libgalago.c:
+	  - Beef up the unit tests by registering as a feed and ensuring that
+	    objects can be created with valid returned object paths.
+
 Tue Feb 07 00:48:17 PST 2006  Christian Hammond <chipx86 at chipx86.com>
 
 	* libgalago/galago-presence.c:

Modified: branches/libgalago/protocol-cleanup/tests/check-libgalago.c
===================================================================
--- branches/libgalago/protocol-cleanup/tests/check-libgalago.c	2006-02-07 08:51:00 UTC (rev 2563)
+++ branches/libgalago/protocol-cleanup/tests/check-libgalago.c	2006-02-07 09:04:32 UTC (rev 2564)
@@ -84,26 +84,57 @@
  **************************************************************************/
 START_TEST(test_create_person)
 {
-	galago_init("check-libgalago", FALSE);
-	fail_unless(make_dummy_person() != NULL, "Unable to create person");
+	GalagoPerson *person;
+
+	galago_init("check-libgalago", TRUE);
+
+	person = make_dummy_person();
+	fail_unless(person != NULL, "Unable to create person");
+	fail_unless(galago_object_get_dbus_path(GALAGO_OBJECT(person)) != NULL,
+				"Object path not set on the new person");
 }
 END_TEST
 
 START_TEST(test_create_service)
 {
-	galago_init("check-libgalago", FALSE);
-	fail_unless(make_dummy_service() != NULL, "Unable to create service");
+	GalagoService *service;
+
+	galago_init("check-libgalago", TRUE);
+
+	service = make_dummy_service();
+	fail_unless(service != NULL, "Unable to create service");
+	fail_unless(galago_object_get_dbus_path(GALAGO_OBJECT(service)) != NULL,
+				"Object path not set on the new service");
 }
 END_TEST
 
 START_TEST(test_create_account)
 {
-	galago_init("check-libgalago", FALSE);
-	fail_unless(make_dummy_account() != NULL, "Unable to create account");
+	GalagoAccount *account;
+
+	galago_init("check-libgalago", TRUE);
+
+	account = make_dummy_account();
+	fail_unless(account != NULL, "Unable to create account");
+	fail_unless(galago_object_get_dbus_path(GALAGO_OBJECT(account)) != NULL,
+				"Object path not set on the new account");
 }
 END_TEST
 
+START_TEST(test_create_presence)
+{
+	GalagoPresence *presence;
 
+	galago_init("check-libgalago", TRUE);
+
+	presence = make_dummy_presence();
+	fail_unless(presence != NULL, "Unable to create presence");
+	fail_unless(galago_object_get_dbus_path(GALAGO_OBJECT(presence)) != NULL,
+				"Object path not set on the new presence");
+}
+END_TEST
+
+
 /**************************************************************************
  * Test D-BUS object signature support
  **************************************************************************/
@@ -286,6 +317,7 @@
 	ADD_TCASE("create_person", test_create_person);
 	ADD_TCASE("create_service", test_create_service);
 	ADD_TCASE("create_account", test_create_account);
+	ADD_TCASE("create_presence", test_create_presence);
 
 	/* Test D-BUS object signature support */
 	ADD_TCASE("dbus_signature_account",  test_dbus_signature_account);



More information about the galago-commits mailing list