Debian Codegraph @

tests/test-rtl.c

raw
1 /*
2 * @file tests/test-basic.c Unit test: basics
3 *
4 * @Copyright (C) 2004 Mike Hearn <[email protected]>
5 *
6 * Test Case by Djihed Afifi <[email protected]>
7 *
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
12 *
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the
20 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21 * Boston, MA 02111-1307, USA.
22 */
23
24 #include <libnotify/notify.h>
25 #include <stdio.h>
26 #include <unistd.h>
27
28 int
29 main ()
30 {
31 NotifyNotification *n;
32
33 notify_init("Basics");
34
35 n = notify_notification_new ("اختبار",
36 "يوفر ويكي عربآيز مناخا للنقاش وتبادل الخبرات والمعرفة حول اللغة العربية ولسانياتها ومايتعلّق بدعمها والإرتقاء بها في الحوسبة عموماً والبرمجيات الحرة على وجه الخصوص. هذا الويكي عبارة عن بيئة تعاونية تشاركية مفتوحة للجميع بدون قيود، لغتنا الجميلة بانتظار مساهمتك فلا تبخل عليها ",
37 NULL);
38 notify_notification_set_timeout (n, 3000);
39
40 if (!notify_notification_show (n, NULL)) {
41 fprintf (stderr, "failed to send notification\n");
42 return 1;
43 }
44
45 g_object_unref (G_OBJECT (n));
46
47 return 0;
48 }