lib: add internal object pool API and use it; adapt plugins/tests
[babeltrace.git] / tests / lib / test_bt_notification_heap.c
index 7fe538ade71bffe44980af35955c1b47334a7222..531ddf680464a4aa3ab6b4173ff52956bd275bdd 100644 (file)
  */
 
 #include "tap/tap.h"
-#include <stdbool.h>
 #include <stdlib.h>
-#include <babeltrace/compiler.h>
+#include <babeltrace/compiler-internal.h>
 #include <babeltrace/ref.h>
-#include <babeltrace/plugin/notification/heap.h>
-#include <babeltrace/plugin/notification/notification.h>
-#include <babeltrace/plugin/notification/notification-internal.h>
+#include <babeltrace/graph/notification-heap.h>
+#include <babeltrace/graph/notification.h>
+#include <babeltrace/graph/notification-internal.h>
 
 #define NR_TESTS 7
 
@@ -46,8 +45,7 @@ void bt_notification_init(struct bt_notification *notification,
                enum bt_notification_type type,
                bt_object_release_func release)
 {
-       assert(type > BT_NOTIFICATION_TYPE_ALL &&
-                       type < BT_NOTIFICATION_TYPE_NR);
+       assert(type > 0 && type < BT_NOTIFICATION_TYPE_NR);
        notification->type = type;
        bt_object_init(&notification->base, release);
 }
@@ -71,7 +69,7 @@ error:
 }
 
 static
-bool compare_notifications(struct bt_notification *a, struct bt_notification *b,
+bt_bool compare_notifications(struct bt_notification *a, struct bt_notification *b,
                void *unused)
 {
        uint64_t val_a = ((struct dummy_notification *) a)->value;
This page took 0.035402 seconds and 4 git commands to generate.