blob: 182fc28b5d1b8910785e491fa4687eddae4825af (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
/* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 8; tab-width: 8 -*- */
/*
* libgfbgraph - GObject library for Facebook Graph API
* Copyright (C) 2018 Yi-Soo An <yisooan@gmail.com>
*
* GFBGraph is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* GFBGraph is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with GFBGraph. If not, see <http://www.gnu.org/licenses/>.
*/
/*
* This code is based on glib/tests/autoptr.c
*/
#include <glib.h>
#include <gfbgraph/gfbgraph.h>
static void
test_gfbgraph_album (void)
{
g_autoptr (GFBGraphAlbum) val = NULL;
val = gfbgraph_album_new ();
g_assert_nonnull (val);
}
static void
test_gfbgraph_node (void)
{
g_autoptr (GFBGraphNode) val = NULL;
val = gfbgraph_node_new ();
g_assert_nonnull (val);
}
static void
test_gfbgraph_photo (void)
{
g_autoptr (GFBGraphPhoto) val = NULL;
val = gfbgraph_photo_new ();
g_assert_nonnull (val);
}
static void
test_gfbgraph_user (void)
{
g_autoptr (GFBGraphUser) val = NULL;
val = gfbgraph_user_new ();
g_assert_nonnull (val);
}
int
main (int argc,
char *argv[])
{
g_test_init (&argc, &argv, NULL);
g_test_add_func ("/GFBGraph/autoptr/Album", test_gfbgraph_album);
g_test_add_func ("/GFBGraph/autoptr/Node", test_gfbgraph_node);
g_test_add_func ("/GFBGraph/autoptr/Photo", test_gfbgraph_photo);
g_test_add_func ("/GFBGraph/autoptr/User", test_gfbgraph_user);
return g_test_run ();
}
|