const gdb::observers::token token1 {}, token2 {} , token3 {};
/* Now, attach one observer, and send a notification. */
- test_notification.attach (&test_second_notification_function, token2);
+ test_notification.attach (&test_second_notification_function, token2, "test");
notify_check_counters (0, 1, 0);
/* Remove the observer, and send a notification. */
notify_check_counters (0, 0, 0);
/* With a new observer. */
- test_notification.attach (&test_first_notification_function, token1);
+ test_notification.attach (&test_first_notification_function, token1, "test");
notify_check_counters (1, 0, 0);
/* With 2 observers. */
- test_notification.attach (&test_second_notification_function, token2);
+ test_notification.attach (&test_second_notification_function, token2, "test");
notify_check_counters (1, 1, 0);
/* With 3 observers. */
- test_notification.attach (&test_third_notification_function, token3);
+ test_notification.attach (&test_third_notification_function, token3, "test");
notify_check_counters (1, 1, 1);
/* Remove middle observer. */
/* Go back to 3 observers, and remove them in a different
order... */
- test_notification.attach (&test_first_notification_function, token1);
- test_notification.attach (&test_second_notification_function, token2);
- test_notification.attach (&test_third_notification_function, token3);
+ test_notification.attach (&test_first_notification_function, token1, "test");
+ test_notification.attach (&test_second_notification_function, token2, "test");
+ test_notification.attach (&test_third_notification_function, token3, "test");
notify_check_counters (1, 1, 1);
/* Remove the third observer. */