[dia] [unit test] comment on DiaObject::create() returned handles



commit 1840dd2127a4c23dec32cde1e6602cc850fde4db
Author: Hans Breuer <hans breuer org>
Date:   Fri Jan 16 22:54:07 2015 +0100

    [unit test] comment on DiaObject::create() returned handles
    
    The first handle is used to connect - if possible.
    Only very few object return in unconnectable handle, namely:
      "Standard - Beziergon", "Standard - Path", "Standard - Polygon",
      "Database - Compound",
      "GRAFCET - Condition",
      "Misc - Ngon",
      "Network - Radio Cell"
    This is not a bug in these object implementations, because other
    uses are possible ...

 tests/test-objects.c |   19 ++++++++++++++++++-
 1 files changed, 18 insertions(+), 1 deletions(-)
---
diff --git a/tests/test-objects.c b/tests/test-objects.c
index 30858b7..6388786 100644
--- a/tests/test-objects.c
+++ b/tests/test-objects.c
@@ -333,7 +333,24 @@ _test_move_handle (gconstpointer user_data)
   ObjectChange *change;
   ConnectionPoint *cp = NULL;
   gint i;
-  
+
+  if (h1)
+    {
+      /* The first handle is used to connect - if possible.
+       * Only very few object return in unconnectable handle, namely:
+       *   "Standard - Beziergon", "Standard - Path", "Standard - Polygon",
+       *   "Database - Compound",
+       *   "GRAFCET - Condition",
+       *   "Misc - Ngon",
+       *   "Network - Radio Cell"
+       * This is not a bug in these object implementations, because other
+       * uses are possible ...
+       */
+      if (h1->connect_type != HANDLE_CONNECTABLE)
+        g_test_message ("Handle 1 not connectable");
+
+    }
+
   if (h2) /* not mandatory to return one */
     {
       Point to = h2->pos;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]